summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2015-05-27 19:40:39 (GMT)
committerStephen Kelly <steveire@gmail.com>2015-06-02 23:04:00 (GMT)
commit80b433b05ea921e6144c10260cfeafb4b25e5bc1 (patch)
tree553806a5a2881ec44690358f9651ff3cc7d9455d
parent52919ac8ac22e1646f8f46907fe9c8e753d954cf (diff)
downloadCMake-80b433b05ea921e6144c10260cfeafb4b25e5bc1.zip
CMake-80b433b05ea921e6144c10260cfeafb4b25e5bc1.tar.gz
CMake-80b433b05ea921e6144c10260cfeafb4b25e5bc1.tar.bz2
cmGlobalGenerator: Don't use else after a return.
-rw-r--r--Source/cmGlobalGenerator.cxx43
1 files changed, 19 insertions, 24 deletions
diff --git a/Source/cmGlobalGenerator.cxx b/Source/cmGlobalGenerator.cxx
index cd05c54..2c2cbd8 100644
--- a/Source/cmGlobalGenerator.cxx
+++ b/Source/cmGlobalGenerator.cxx
@@ -87,18 +87,16 @@ bool cmGlobalGenerator::SetGeneratorPlatform(std::string const& p,
{
return true;
}
- else
- {
- std::ostringstream e;
- e <<
- "Generator\n"
- " " << this->GetName() << "\n"
- "does not support platform specification, but platform\n"
- " " << p << "\n"
- "was specified.";
- mf->IssueMessage(cmake::FATAL_ERROR, e.str());
- return false;
- }
+
+ std::ostringstream e;
+ e <<
+ "Generator\n"
+ " " << this->GetName() << "\n"
+ "does not support platform specification, but platform\n"
+ " " << p << "\n"
+ "was specified.";
+ mf->IssueMessage(cmake::FATAL_ERROR, e.str());
+ return false;
}
bool cmGlobalGenerator::SetGeneratorToolset(std::string const& ts,
@@ -108,18 +106,15 @@ bool cmGlobalGenerator::SetGeneratorToolset(std::string const& ts,
{
return true;
}
- else
- {
- std::ostringstream e;
- e <<
- "Generator\n"
- " " << this->GetName() << "\n"
- "does not support toolset specification, but toolset\n"
- " " << ts << "\n"
- "was specified.";
- mf->IssueMessage(cmake::FATAL_ERROR, e.str());
- return false;
- }
+ std::ostringstream e;
+ e <<
+ "Generator\n"
+ " " << this->GetName() << "\n"
+ "does not support toolset specification, but toolset\n"
+ " " << ts << "\n"
+ "was specified.";
+ mf->IssueMessage(cmake::FATAL_ERROR, e.str());
+ return false;
}
std::string cmGlobalGenerator::SelectMakeProgram(