summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2010-06-29 14:01:59 (GMT)
committerBrad King <brad.king@kitware.com>2010-06-29 14:01:59 (GMT)
commitc8ea2705a7115208f59839828a82b42a58293576 (patch)
treef5937e1117a7bea6ad03d6a2b5209610a34db4a5
parent295b5b60df5d9427fdb891fd51333c12089ee129 (diff)
downloadCMake-c8ea2705a7115208f59839828a82b42a58293576.zip
CMake-c8ea2705a7115208f59839828a82b42a58293576.tar.gz
CMake-c8ea2705a7115208f59839828a82b42a58293576.tar.bz2
Use same type in both cases of '?:' operator
Both possible result values need to be convertible to the same type. Some compilers fail to recognize that they can construct std::string from the empty string literal, so state it explicitly.
-rw-r--r--Source/cmCoreTryCompile.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/Source/cmCoreTryCompile.cxx b/Source/cmCoreTryCompile.cxx
index fcec3e9..b8a0c95 100644
--- a/Source/cmCoreTryCompile.cxx
+++ b/Source/cmCoreTryCompile.cxx
@@ -178,7 +178,7 @@ int cmCoreTryCompile::TryCompileCode(std::vector<std::string> const& argv)
const char* rulesOverrideBase = "CMAKE_USER_MAKE_RULES_OVERRIDE";
std::string rulesOverrideLang =
- rulesOverrideBase + (lang ? std::string("_") + lang : "");
+ rulesOverrideBase + (lang ? std::string("_") + lang : std::string(""));
if(const char* rulesOverridePath =
this->Makefile->GetDefinition(rulesOverrideLang.c_str()))
{