cdepillabout / pretty-simple

pretty-printer for Haskell data types that have a Show instance
https://hackage.haskell.org/package/pretty-simple
BSD 3-Clause "New" or "Revised" License
243 stars 29 forks source link

The parser fails to parse strings with escaped quotation marks #40

Closed anka-213 closed 6 years ago

anka-213 commented 6 years ago

Currently, escaped quotation marks within strings are interpreted as the end of a string. For example, if show gave this:

Foo "hello \" world!"

The parser would give back:

> parseExprs "Foo \"hello \\\"world!\""
([Other "Foo ",StringLit "hello \\",Other "world!",StringLit ""],"")

instead of the expected

([Other "Foo ",StringLit "hello \\\" world!"],"")
dminuoso commented 5 years ago

Would be great if you could push 2.2.0.1 to hackage to include this fix. :)

cdepillabout commented 5 years ago

@dminuoso Pushed it to Hackage!

https://hackage.haskell.org/package/pretty-simple-2.2.0.1