CMake/Help/release/dev/regex-fixes.rst
Nikita Nemkin 8d455809b0 string: Allow zero-length matches in all REGEX subcommands
The semantics mimic other languages like Python, Java, JS, etc.
To advance past a zero-length match, the search algorithm first
tries to find a non-zero alternative branch. If that fails, it
force-advances by 1 character.

Fixes: #13790, #13792, #18690, #26629
2025-02-15 01:01:49 +05:00

11 lines
295 B
ReStructuredText

regex-fixes
-----------
* Regular expressions match the ``^`` anchor at most once in repeated
searches, at the start of the input. See policy :policy:`CMP0186`.
* References to unmatched groups are allowed, they are replaced with empty
strings.
* Zero-length matches are always allowed.