Help: Clarify documentation on regex character classes
CMake regex parsing was giving me troubles when trying to match a character class that contains a closing bracket ]
.
I could only get string(REPLACE REGEX ...)
to work if if put the bracket right after the opening bracket e.g. []ab]
.
Any number of backslashes (tried up to 5) didn't allow me to put the closing bracket anywhere else. [a]b]
doesn't work (as expected). But also [a\]b]
or [a\\]b]
etc. don't give me the desired result.
Updated the documentation in the same style as it's done for a literal -
in character classes.
Topic-rename: doc-regex-classes
Edited by Brad King