I am confused with a very simple example. I have a standard list, so basically its string representation uses semicolon as delimiters. I want to replace it by another one:
set(L1 "A" "B" "C")
message("L1: ${L1}")
string(REPLACE ";" "<->" L2 ${L1})
message("L2: ${L2}")
this snippet prints:
L1: A;B;C
L2: ABC
and I don't understand why. According to some other SO answers, my string replacement seems valid. What am I doing wrong ? Is there a way to store the value A<->B<->C
in my 2nd variable ?
Note: I use CMake 3.7.2