You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A literal ^M character in a string will cause jsown to misparse numbers.
In the code below I wrote ^M as explicitly two characters where you could see it, otherwise the
github markup system interpreted it as a carriage return.
The issue of reading with a return character in the string was
mentioned in #26.
This change idea allows for setting the :junk-allowed option when
reading numbers. This option allows for more freedom then necessary,
but the performance implications seem very minimal. Although we
should consider alternatives, setting the (unexported)
`jsown::*allow-junk-in-integers-p*` parameter to a truethy value will
allow such reading at the moment. As we ponder on alternatives a
better solution may be found.
It is currently optional as there might be side-effects and there is
probably a cleaner option. The current solution allows for random
junk where we should probably only allow whitespace. Nevertheless,
the solution may help should someone be stuck.
Hello,
A literal ^M character in a string will cause jsown to misparse numbers.
In the code below I wrote ^M as explicitly two characters where you could see it, otherwise the
github markup system interpreted it as a carriage return.
I worked around it by stripping all \r and \n characters from my strings before parsing them, but I figured you'd want to know.
Thank you.
The text was updated successfully, but these errors were encountered: