diff options
author | Andy Cedilnik <andy.cedilnik@kitware.com> | 2005-01-26 15:10:41 (GMT) |
---|---|---|
committer | Andy Cedilnik <andy.cedilnik@kitware.com> | 2005-01-26 15:10:41 (GMT) |
commit | f7063fc6612ad461e0d1a6dbc5a6da2366c0812e (patch) | |
tree | 8da6d57c76a902acc2fb253fb7e8030a41a0f799 /Source/cmCTest.cxx | |
parent | cbe845f7ef7a998a3b41f42ac5696432176a0a21 (diff) | |
download | CMake-f7063fc6612ad461e0d1a6dbc5a6da2366c0812e.zip CMake-f7063fc6612ad461e0d1a6dbc5a6da2366c0812e.tar.gz CMake-f7063fc6612ad461e0d1a6dbc5a6da2366c0812e.tar.bz2 |
ENH: Add method to populate custom integers
Diffstat (limited to 'Source/cmCTest.cxx')
-rw-r--r-- | Source/cmCTest.cxx | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/Source/cmCTest.cxx b/Source/cmCTest.cxx index 4080811..302ba52 100644 --- a/Source/cmCTest.cxx +++ b/Source/cmCTest.cxx @@ -2148,6 +2148,20 @@ void cmCTest::PopulateCustomVector(cmMakefile* mf, const char* def, tm_VectorOfS } } +void cmCTest::PopulateCustomInteger(cmMakefile* mf, const char* def, int& val) +{ + if ( !def) + { + return; + } + const char* dval = mf->GetDefinition(def); + if ( !dval ) + { + return; + } + val = atoi(dval); +} + std::string cmCTest::GetShortPathToFile(const char* cfname) { const std::string& sourceDir = GetDartConfiguration("SourceDirectory"); |