MantisBT - CMake | ||||||||||
View Issue Details | ||||||||||
ID | Project | Category | View Status | Date Submitted | Last Update | |||||
0008823 | CMake | CMake | public | 2009-03-31 12:20 | 2015-07-08 08:57 | |||||
Reporter | James Bigler | |||||||||
Assigned To | Bill Hoffman | |||||||||
Priority | normal | Severity | minor | Reproducibility | always | |||||
Status | closed | Resolution | fixed | |||||||
Platform | OS | OS Version | ||||||||
Product Version | CMake-2-6 | |||||||||
Target Version | Fixed in Version | CMake 3.1 | ||||||||
Summary | 0008823: if(variable STREQUAL string) can treak LHS as a variable name | |||||||||
Description | Consider the following code snippet. set(var "stuff") set(stuff ON) if(var STREQUAL "stuff") message("var STREQUAL stuff") else() message("NOT var STREQUAL stuff") endif() According to the documentation, the LHS of STREQUAL should be treated as a string. if(variable STREQUAL string) if(string STREQUAL string) However the behavior of the if statement changes depending on if 'stuff' is defined contrary to the documentation. For comparison, MATCHES works as expected (results not dependent on the variable 'stuff' being defined). | |||||||||
Steps To Reproduce | ||||||||||
Additional Information | ||||||||||
Tags | No tags attached. | |||||||||
Relationships |
| |||||||||
Attached Files | ||||||||||
Issue History | ||||||||||
Date Modified | Username | Field | Change | |||||||
2009-03-31 12:20 | James Bigler | New Issue | ||||||||
2009-05-05 14:58 | mwoehlke | Note Added: 0016297 | ||||||||
2009-09-14 12:51 | Bill Hoffman | Status | new => assigned | |||||||
2009-09-14 12:51 | Bill Hoffman | Assigned To | => Bill Hoffman | |||||||
2009-09-14 13:26 | James Bigler | Note Added: 0017447 | ||||||||
2010-11-30 16:26 | James Bigler | Relationship added | related to 0008226 | |||||||
2015-02-26 16:12 | Stephen Kelly | Note Added: 0038090 | ||||||||
2015-02-26 16:12 | Stephen Kelly | Status | assigned => resolved | |||||||
2015-02-26 16:12 | Stephen Kelly | Fixed in Version | => CMake 3.1 | |||||||
2015-02-26 16:12 | Stephen Kelly | Resolution | open => fixed | |||||||
2015-07-08 08:57 | Robert Maynard | Note Added: 0039079 | ||||||||
2015-07-08 08:57 | Robert Maynard | Status | resolved => closed |
Notes | |||||
|
|||||
|
|
||||
|
|||||
|
|
||||
|
|||||
|
|
||||
|
|||||
|
|