on master help sign in
remove 'to' in error message
commitdd46e2251aef9e8cd76113247732b5e28a6079ec authorgrdvnl <grdvnl@gmail.com> dateTue 15 Oct 2019, 21:23 (7 years ago) parent8073909
2 files changed+2−2
Data/Aeson/Types/FromJSON.hs+1−1 tests/golden/generic.expected+1−1
Data/Aeson/Types/FromJSON.hs+1−1
@@ -959,7 +959,7 @@ contextType = prependContext
959959contextTag :: Text -> [String] -> Parser a -> Parser a
960960contextTag tagKey cnames = prependFailure
961961 ("expected Object with key \"" ++ unpack tagKey ++ "\"" ++
962− " containing to one of " ++ show cnames ++ ", ")
962+ " containing one of " ++ show cnames ++ ", ")
963963
964964-- | Add the name of the constructor being parsed to a parser's error messages.
965965contextCons :: ConName -> TypeName -> Parser a -> Parser a
tests/golden/generic.expected+1−1
@@ -10,7 +10,7 @@ Error in $: parsing Types.SomeType(Unary) failed, key "contents" not found
1010Error in $: parsing Types.SomeType(Record) failed, key "testone" not found
1111Error in $.testone: parsing Double failed, unexpected Boolean
1212Error in $.tag: parsing Types.SomeType failed, expected tag field to be one of ["nullary","unary","product","record","list"], but found tag "X"
13−Error in $: parsing Types.SomeType failed, expected Object with key "tag" containing to one of ["nullary","unary","product","record","list"], key "tag" not found
13+Error in $: parsing Types.SomeType failed, expected Object with key "tag" containing one of ["nullary","unary","product","record","list"], key "tag" not found
1414Error in $: parsing Types.SomeType failed, expected Object, but encountered Array
1515SomeType (single-field)
1616Error in $.unary: parsing Int failed, expected Number, but encountered Object