typed-encoding v0.3 Release Notes
-
💥 Breaking: Numerous changes on the implementation side, new version should be largely compatible on the call site except for small differences in constraints and order for type variables (if
-XTypeApplications
is used). See v3 migration guide.EncodeFAll
,DecodeFAll
,RecreateFAll
,EncodeF
,DecodeF
,RecreateF
replaced withEncodeAll
,DecodeAll
,ValidateAll
,Encode
,Decode
,Validate
.- functions used to create encoding instances or encoding combinators (e.g.
implEncodeP
) are now more precisely typed Displ String
instance (used in examples, has been made consistent with Text and ByteString)- Modules under
Data.TypedEncoding.Combinators
merged intoData.TypedEncoding.Instances
. - Modules under
Data.TypedEncoding.Internal
have been reorganized and moved outside ofInternal
. Various changes that make the library easier to navigate. for better navigation and discovery. - some previously exported combinators (e.g.
implTranF
) have moved toData.TypedEncoding.Instances.Support.Unsafe
ToEncString
,FromEncString
have more type variables and function name but backward compatible functions have been provided.Superset
typeclass removed, replaced withIsSuperset
type family.- Minor changes in
forall
variable order in combinators for"r-bool:"
encodings. Encoder
type removed, replaced byEncodings
.checkWithValidationsEnc
combinator renamed tocheck
- (Considered private)
MkCheckedEnc
constructor becameUnsafeMkCheckedEnc
- (Considered private)
MkEnc
constructor becameUnsafeMkEnc
🆕 new functionality
- new types and typeclasses are based on both encoding name and algorithm name allowing
typeclass definitions for open encodings like
"r-ban:"
that can contain arbitrary symbol literals. - new set of combinators grouped into
_
(compiler decided algorithm),'
(program specifies algorithm), andalgorithm name ~ encoding name
categories above
combinator subsumes partial encoding / decoding combinatorsEncodingSuperset
class added
- new types and typeclasses are based on both encoding name and algorithm name allowing
typeclass definitions for open encodings like