ridiculousfish / regress

REGex in Rust with EcmaScript Syntax
Apache License 2.0
176 stars 11 forks source link

Require \ for unicode-escapes in named captures #67

Closed sirosen closed 1 year ago

sirosen commented 1 year ago

This resolves #41

Rather than only looking for 'u', look for something ever so slightly more strict: "\\u".

This passes the existing tests and a very simple additional test which reproduces the issue from #41.


Minor caveat: I'm not an experienced hand at Rust. If I need to do more sophisticated work here, I am very willing to try my best but might not have the skills for it yet. :sweat_smile:

ridiculousfish commented 1 year ago

Merged as 4026d98d1efd2cf934ade1987bc1c1aa0ac6efda. Thank you!