samisagit / natskell

A NATS client library written in Haskell
MIT License
7 stars 0 forks source link

Add generic parser #62

Closed samisagit closed 2 years ago

samisagit commented 2 years ago

Restructures the project allowing for a generic parser.

Parsers need to return the same type as each other, but the type needs to know what the sub return type should be. Now all parsers are in the same module (as well as transformers though these have been moved to typeclass instances). All types are now under the nest of Types..

Tests can now prove that bytestrings passed to a generic parser will return the correct data structure (given valid input).

Closes #60 #61 and #24