Closed kerhong closed 8 months ago
I'm not sure I value a stable parse/encode cycle as much as I value ergonomics for users.
That said, there are facets of this that might be improved with change:
It might be that we should treat only 1
as true
and 0
as false
and error on any other value,
however given how closely aligned the client is with the semantics of C++ where any positive integer is true
this might be setting ourselves up for failure.
Currently
bool
is read as any non 0 value, but written as1
.This means
[5] -> parse_as_bool -> true -> encode -> [1]
.Having stable parse->encode would help find other issues with fuzzing (see #83)
from #77