tinystr icon indicating copy to clipboard operation
tinystr copied to clipboard

Parse escape sequeces in macros

Open ironhaven opened this issue 3 years ago • 1 comments

The sketchy string literal parser is now less sketchy!

If a string with escape sequences is passed to any macro this patch will parse the escapes. It will parse all escapes listed in the rust reference except for \u{XXXX} Unicode escapes because they are complicated and non-ASCII is explicitly unsupported.

All in the name of not adding syn to Cargo.toml.

ironhaven avatar Jun 10 '21 16:06 ironhaven

Would it be possible to rely on the absolution crate for this? That crate is explicitly designed for avoiding a syn dep but getting full token parsing

Manishearth avatar Jun 13 '21 16:06 Manishearth