BUG: Fix impl of CMP0005 regex to match value-less definitions.
This commit is contained in:
parent
a340fd42b8
commit
3374d12ff0
|
@ -1024,7 +1024,7 @@ bool cmMakefile::ParseDefineFlag(std::string const& def, bool remove)
|
||||||
{
|
{
|
||||||
// Create a regular expression to match valid definitions.
|
// Create a regular expression to match valid definitions.
|
||||||
static cmsys::RegularExpression
|
static cmsys::RegularExpression
|
||||||
valid("^[-/]D[A-Za-z_][A-Za-z0-9_]*(=.*)$");
|
valid("^[-/]D[A-Za-z_][A-Za-z0-9_]*(=.*)?$");
|
||||||
|
|
||||||
// Make sure the definition matches.
|
// Make sure the definition matches.
|
||||||
if(!valid.find(def.c_str()))
|
if(!valid.find(def.c_str()))
|
||||||
|
|
Loading…
Reference in New Issue