Page 1 of 1

semicolon for define

Posted: Thu Oct 08, 2020 7:26 pm
by Jarod42
`;` is used as separator for C/C++ Compiler options and in Preprocessors. (probably not the only place though).

How can we "escape" it for regular use?

Code: Select all

-D"SEMICOLON=;"

Re: semicolon for define

Posted: Sat Oct 10, 2020 6:18 pm
by eranif
Basically passing "strings" as macros, should be double wrapped, so it should be done like this:

Code: Select all

-DSEP=\"";"\"
The problem is that CodeLite does not parse this correctly in the project settings -> compiler -> pre-processor section

I did fix that in git master, but this is not released yet

Eran

Re: semicolon for define

Posted: Sat Oct 10, 2020 10:41 pm
by Jarod42
My problem is semi colon, I succeed to escape quote (normally).

Will look at the fix later.