Releases: fancy-regex/fancy-regex
Releases · fancy-regex/fancy-regex
0.13.0
Added
- Support for relative backreferences using
\k<-1>
(-1 references the
previous group) (#121) - Add
try_replacen
toRegex
which returns aResult
instead of panicking
when matching errors (#130)
Changed
- Switch from regex crate to regex-automata and regex-syntax (lower level APIs)
to simplify internals (#121) - Allow escaping some letters in character classes, e.g.
[\A]
used to error
but now matches the same as[A]
(for compatibility with Oniguruma) - MSRV (minimum supported Rust version) is now 1.66.1 (from 1.61.0)
Fixed
- Fix index out of bounds panic when parsing unclosed
(?(
(#125)
0.12.0
0.11.0
Added
- Support for conditionals: using a regex like
(?<test>a)?b(?(test)c|d)
will try to matchc
afterb
ifa
matched in the capture group named
test
, otherwised
afterb
ifa
wasn't captured into thetest
group.
Changed
- Updated parse errors to show the position they occurred at.
Fixed
- Fix panic when backref is used within referenced group itself and
group end index is not known yet (#103)
0.10.0
Added
- Support for
\G
(anchor to end of previous match): Using a regex
like\G\w
will match each letter offoo
infoo bar
but
nothing else.