summaryrefslogtreecommitdiffstats
path: root/Source/cmMakefile.cxx
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2016-01-28 21:10:28 (GMT)
committerBrad King <brad.king@kitware.com>2016-08-25 13:47:26 (GMT)
commit2af853deb5225a9c8cb3d1e6311680c3fb7d86aa (patch)
treef5728597309b170b4b99b2c84596446ed651bf4e /Source/cmMakefile.cxx
parent33bb9cfa365f494bb76ff9c2c78ad625e77152ec (diff)
downloadCMake-2af853deb5225a9c8cb3d1e6311680c3fb7d86aa.zip
CMake-2af853deb5225a9c8cb3d1e6311680c3fb7d86aa.tar.gz
CMake-2af853deb5225a9c8cb3d1e6311680c3fb7d86aa.tar.bz2
cmMakefile: Simplify IssueMessage implementation
It is only called during configure time when the execution stack is non-empty.
Diffstat (limited to 'Source/cmMakefile.cxx')
-rw-r--r--Source/cmMakefile.cxx8
1 files changed, 3 insertions, 5 deletions
diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx
index b9d71ec..d299b8b 100644
--- a/Source/cmMakefile.cxx
+++ b/Source/cmMakefile.cxx
@@ -115,11 +115,9 @@ cmMakefile::~cmMakefile()
void cmMakefile::IssueMessage(cmake::MessageType t,
std::string const& text) const
{
- // Collect context information.
- if (!this->ExecutionStatusStack.empty()) {
- if ((t == cmake::FATAL_ERROR) || (t == cmake::INTERNAL_ERROR)) {
- this->ExecutionStatusStack.back()->SetNestedError(true);
- }
+ assert(!this->ExecutionStatusStack.empty());
+ if ((t == cmake::FATAL_ERROR) || (t == cmake::INTERNAL_ERROR)) {
+ this->ExecutionStatusStack.back()->SetNestedError(true);
}
this->GetCMakeInstance()->IssueMessage(t, text, this->GetBacktrace());
}