diff options
author | Brad King <brad.king@kitware.com> | 2017-09-13 12:34:49 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2017-09-13 12:35:05 (GMT) |
commit | 67810849b95acfe036a9a605dbda6f0a3d6f7493 (patch) | |
tree | fa63356603dd00956f306eb92d4ecdbca9e450d4 /Source/cmFunctionCommand.cxx | |
parent | a763cffd6b65bbe5572527e39969981bf31d5aca (diff) | |
parent | 7d5095796ab616cf9b709036387bb95ab9984141 (diff) | |
download | CMake-67810849b95acfe036a9a605dbda6f0a3d6f7493.zip CMake-67810849b95acfe036a9a605dbda6f0a3d6f7493.tar.gz CMake-67810849b95acfe036a9a605dbda6f0a3d6f7493.tar.bz2 |
Merge topic 'ranged-for'
7d509579 Meta: modernize old-fashioned loops to range-based `for`.
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1249
Diffstat (limited to 'Source/cmFunctionCommand.cxx')
-rw-r--r-- | Source/cmFunctionCommand.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/cmFunctionCommand.cxx b/Source/cmFunctionCommand.cxx index ee52bde..74230b0 100644 --- a/Source/cmFunctionCommand.cxx +++ b/Source/cmFunctionCommand.cxx @@ -104,9 +104,9 @@ bool cmFunctionHelperCommand::InvokeInitialPass( // Invoke all the functions that were collected in the block. // for each function - for (unsigned int c = 0; c < this->Functions.size(); ++c) { + for (cmListFileFunction const& func : this->Functions) { cmExecutionStatus status; - if (!this->Makefile->ExecuteCommand(this->Functions[c], status) || + if (!this->Makefile->ExecuteCommand(func, status) || status.GetNestedError()) { // The error message should have already included the call stack // so we do not need to report an error here. |