Definite's Extractor

My findings on Life, Linux, Open Source, and so on.

CMake String regex match annoyance

CMake has a regex string matching function STRING(REGEX MATCH … ), but it does not work as normal regex should. Firstly, as quite a bit people already aware of, it does not recognize the beginning-of-string ‘^’ and end-of-string ‘$’.

I also recently found that ‘;’ in the input string will be stripped, so be aware of that.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: