summaryrefslogtreecommitdiffstats
path: root/Source/cmCommands.cxx
diff options
context:
space:
mode:
authorKyle Edwards <kyle.edwards@kitware.com>2021-06-16 14:39:39 (GMT)
committerKyle Edwards <kyle.edwards@kitware.com>2021-06-16 14:39:39 (GMT)
commitc017098d4d06ba114085ba7de47b99fc0b71e8d0 (patch)
treeeabd3fa444c96599d490b12ab49cbccda21866d3 /Source/cmCommands.cxx
parenta9ff600a509d6af1c25f482e1ce0184c97dd3f54 (diff)
downloadCMake-c017098d4d06ba114085ba7de47b99fc0b71e8d0.zip
CMake-c017098d4d06ba114085ba7de47b99fc0b71e8d0.tar.gz
CMake-c017098d4d06ba114085ba7de47b99fc0b71e8d0.tar.bz2
CMake: Allow override of unexpected non-flow-control commands
Fixes: #22310
Diffstat (limited to 'Source/cmCommands.cxx')
-rw-r--r--Source/cmCommands.cxx14
1 files changed, 7 insertions, 7 deletions
diff --git a/Source/cmCommands.cxx b/Source/cmCommands.cxx
index 9e5b783..a241a3a 100644
--- a/Source/cmCommands.cxx
+++ b/Source/cmCommands.cxx
@@ -164,36 +164,36 @@ void GetScriptingCommands(cmState* state)
state->AddBuiltinCommand("string", cmStringCommand);
state->AddBuiltinCommand("unset", cmUnsetCommand);
- state->AddUnexpectedCommand(
+ state->AddUnexpectedFlowControlCommand(
"else",
"An ELSE command was found outside of a proper "
"IF ENDIF structure. Or its arguments did not match "
"the opening IF command.");
- state->AddUnexpectedCommand(
+ state->AddUnexpectedFlowControlCommand(
"elseif",
"An ELSEIF command was found outside of a proper "
"IF ENDIF structure.");
- state->AddUnexpectedCommand(
+ state->AddUnexpectedFlowControlCommand(
"endforeach",
"An ENDFOREACH command was found outside of a proper "
"FOREACH ENDFOREACH structure. Or its arguments did "
"not match the opening FOREACH command.");
- state->AddUnexpectedCommand(
+ state->AddUnexpectedFlowControlCommand(
"endfunction",
"An ENDFUNCTION command was found outside of a proper "
"FUNCTION ENDFUNCTION structure. Or its arguments did not "
"match the opening FUNCTION command.");
- state->AddUnexpectedCommand(
+ state->AddUnexpectedFlowControlCommand(
"endif",
"An ENDIF command was found outside of a proper "
"IF ENDIF structure. Or its arguments did not match "
"the opening IF command.");
- state->AddUnexpectedCommand(
+ state->AddUnexpectedFlowControlCommand(
"endmacro",
"An ENDMACRO command was found outside of a proper "
"MACRO ENDMACRO structure. Or its arguments did not "
"match the opening MACRO command.");
- state->AddUnexpectedCommand(
+ state->AddUnexpectedFlowControlCommand(
"endwhile",
"An ENDWHILE command was found outside of a proper "
"WHILE ENDWHILE structure. Or its arguments did not "