summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2017-02-15 14:40:07 (GMT)
committerBrad King <brad.king@kitware.com>2017-03-10 15:19:54 (GMT)
commita05fc93ee6ce563bbc6bb23e4540cd7bc2f4e52a (patch)
tree1b80b0eac952c9e451bbf25208c528896ca1c4e3
parent895b89046601e61f6fb76bf17c5306ea102b9bf6 (diff)
downloadCMake-a05fc93ee6ce563bbc6bb23e4540cd7bc2f4e52a.zip
CMake-a05fc93ee6ce563bbc6bb23e4540cd7bc2f4e52a.tar.gz
CMake-a05fc93ee6ce563bbc6bb23e4540cd7bc2f4e52a.tar.bz2
VS: Add method to clear flag tables of option parser
-rw-r--r--Source/cmVisualStudioGeneratorOptions.cxx7
-rw-r--r--Source/cmVisualStudioGeneratorOptions.h3
2 files changed, 10 insertions, 0 deletions
diff --git a/Source/cmVisualStudioGeneratorOptions.cxx b/Source/cmVisualStudioGeneratorOptions.cxx
index dfe5ce6..3f9ef94 100644
--- a/Source/cmVisualStudioGeneratorOptions.cxx
+++ b/Source/cmVisualStudioGeneratorOptions.cxx
@@ -81,6 +81,13 @@ void cmVisualStudioGeneratorOptions::AddTable(cmVS7FlagTable const* table)
}
}
+void cmVisualStudioGeneratorOptions::ClearTables()
+{
+ for (int i = 0; i < FlagTableCount; ++i) {
+ this->FlagTable[i] = CM_NULLPTR;
+ }
+}
+
void cmVisualStudioGeneratorOptions::FixExceptionHandlingDefault()
{
// Exception handling is on by default because the platform file has
diff --git a/Source/cmVisualStudioGeneratorOptions.h b/Source/cmVisualStudioGeneratorOptions.h
index 8c49470..f6cc7ec 100644
--- a/Source/cmVisualStudioGeneratorOptions.h
+++ b/Source/cmVisualStudioGeneratorOptions.h
@@ -43,6 +43,9 @@ public:
// Add a table of flags.
void AddTable(cmVS7FlagTable const* table);
+ // Clear the flag tables.
+ void ClearTables();
+
// Store options from command line flags.
void Parse(const char* flags);
void ParseFinish();