ENH: use the string class to force the dec compiler to instantiate some templates

This commit is contained in:
Bill Hoffman 2002-03-07 12:13:45 -05:00
parent 9097446e90
commit 61e87c3a6d
3 changed files with 18 additions and 3 deletions

View File

@ -471,7 +471,12 @@ int main()
cmFailed("the LOAD_CACHE or CONFIGURE_FILE command is broken, "
"CACHE_TEST_VAR_INTERNAL is not defined.");
#else
if(strcmp(CACHE_TEST_VAR_INTERNAL, "bar") != 0)
std::string cachetest = CACHE_TEST_VAR_INTERNAL;
std::string copy = cachetest;
cachetest.find("bar");
cachetest.rfind("bar");
copy = cachetest.substr(0, cachetest.size());
if(cachetest != "bar")
{
cmFailed("the LOAD_CACHE or CONFIGURE_FILE command is broken, "
"CACHE_TEST_VAR_INTERNAL == ", CACHE_TEST_VAR_INTERNAL);

View File

@ -471,7 +471,12 @@ int main()
cmFailed("the LOAD_CACHE or CONFIGURE_FILE command is broken, "
"CACHE_TEST_VAR_INTERNAL is not defined.");
#else
if(strcmp(CACHE_TEST_VAR_INTERNAL, "bar") != 0)
std::string cachetest = CACHE_TEST_VAR_INTERNAL;
std::string copy = cachetest;
cachetest.find("bar");
cachetest.rfind("bar");
copy = cachetest.substr(0, cachetest.size());
if(cachetest != "bar")
{
cmFailed("the LOAD_CACHE or CONFIGURE_FILE command is broken, "
"CACHE_TEST_VAR_INTERNAL == ", CACHE_TEST_VAR_INTERNAL);

View File

@ -471,7 +471,12 @@ int main()
cmFailed("the LOAD_CACHE or CONFIGURE_FILE command is broken, "
"CACHE_TEST_VAR_INTERNAL is not defined.");
#else
if(strcmp(CACHE_TEST_VAR_INTERNAL, "bar") != 0)
std::string cachetest = CACHE_TEST_VAR_INTERNAL;
std::string copy = cachetest;
cachetest.find("bar");
cachetest.rfind("bar");
copy = cachetest.substr(0, cachetest.size());
if(cachetest != "bar")
{
cmFailed("the LOAD_CACHE or CONFIGURE_FILE command is broken, "
"CACHE_TEST_VAR_INTERNAL == ", CACHE_TEST_VAR_INTERNAL);