Skip to content

v0.8.0

Compare
Choose a tag to compare
@slevithan slevithan released this 19 Dec 07:52
· 73 commits to main since this release

🚨 Breaking

  • When option allowUnhandledGAnchors is enabled, an unsupported use of \G no longer adds flag y (provides better tradeoffs).

🚀 Features

  • Added option rules.captureGroup (equivalent to Oniguruma compile-time option ONIG_OPTION_CAPTURE_GROUP) to toDetails, toRegExp, and toOnigurumaAst. Allows unnamed captures and numbered backreferences/subroutines when using named capture (with complex resulting rules in edge cases).

🐞 Fixes

  • Prevent ^ from matching after a string-terminating line feed. (#9)
  • When option avoidSubclass is not enabled, use emulation groups (which prevent captured values from appearing on match results) for copies of capturing groups created by recursion.