to_sexp: never fail representing json as sexp
This doesn't do the same thing as the previous to_sexp function (which went through decode_string to match encode_string and use the Hex representation of the string). Could you give more details about what you're trying to fix here @vbmithr ?
The goal was to have a to_sexp function that would never fail (I didn't care about the exact sexp shape as long as it made sense and was useful as a debugging/printing purpose).
Could you explain why to_sexp was written like this in the first place? Like why it would stringify a piece of json and raise an exception in some cases? I've never seen to_sexp functions to raise an exception half of the times in other libraries, i.e. Jane Street ones.