Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
`encode` does not resolve ambiguity between string and numeric values #22
This one is related to #20.
As you can see the
There are two ways of solving this:
I again vote for the first way.
#20 would require a complete overhaul of the encoding/decoding situation. It's not really a solution, it's creating a new system. For my own uses (and I think many others), the convenience of ToJSON/FromJSON isn't something we're going to give up on. But there's nothing stopping you from having your own ToYAML/FromYAML typeclasses.
Meanwhile, I think it's worth looking at option (2).
Here's my vote to do something about this. The issue makes the yaml library unusable for me, because files which are written cannot be read back if they contain strings properties which happen to be even somewhat numeric. UTCTime is another type which can't be read back once written.