on master help sign in
Merge pull request #521 from Lysxia/comments
c9d9fdcAdam Bergmark
Data/Aeson/Types/Internal.hs+3−3
@@ -554,18 +554,18 @@ data SumEncoding =
554 -- the 'contentsFieldName' field.
554 -- the 'contentsFieldName' field.
555 | UntaggedValue
555 | UntaggedValue
556 -- ^ Constructor names won't be encoded. Instead only the contents of the
556 -- ^ Constructor names won't be encoded. Instead only the contents of the
557− -- constructor will be encoded as if the type had single constructor. JSON
557+ -- constructor will be encoded as if the type had a single constructor. JSON
558 -- encodings have to be disjoint for decoding to work properly.
558 -- encodings have to be disjoint for decoding to work properly.
559 --
559 --
560 -- When decoding, constructors are tried in the order of definition. If some
560 -- When decoding, constructors are tried in the order of definition. If some
561 -- encodings overlap, the first one defined will succeed.
561 -- encodings overlap, the first one defined will succeed.
562 --
562 --
563− -- /Note:/ Nullary constructors are encoded as the string (using
563+ -- /Note:/ Nullary constructors are encoded as strings (using
564 -- 'constructorTagModifier'). Having a nullary constructor alongside a
564 -- 'constructorTagModifier'). Having a nullary constructor alongside a
565 -- single field constructor that encodes to a string leads to ambiguity.
565 -- single field constructor that encodes to a string leads to ambiguity.
566 --
566 --
567 -- /Note:/ Only the last error is kept when decoding, so in the case of
567 -- /Note:/ Only the last error is kept when decoding, so in the case of
568− -- mailformed JSON, only an error for the last constructor will be reported.
568+ -- malformed JSON, only an error for the last constructor will be reported.
569 | ObjectWithSingleField
569 | ObjectWithSingleField
570 -- ^ A constructor will be encoded to an object with a single
570 -- ^ A constructor will be encoded to an object with a single
571 -- field named after the constructor tag (modified by the
571 -- field named after the constructor tag (modified by the