Added an option to specify the C++ language standard in the GUI, this prevents false syntax errors from being presented in projects containing certain C++ features.

PiperOrigin-RevId: 209590353
diff --git a/src/TulsiGenerator/TulsiOptionSet.swift b/src/TulsiGenerator/TulsiOptionSet.swift
index c921570..cecf691 100644
--- a/src/TulsiGenerator/TulsiOptionSet.swift
+++ b/src/TulsiGenerator/TulsiOptionSet.swift
@@ -22,6 +22,10 @@
   case
       // Whether or not to search user header paths first when resolving angle bracket includes.
       ALWAYS_SEARCH_USER_PATHS,
+
+      // What C++ language standard to use for the project.
+      CLANG_CXX_LANGUAGE_STANDARD,
+
       // The path to the Bazel binary.
       BazelPath,
       // Whether or not to claim Swift code was created at the same version as Tulsi itself.
@@ -310,6 +314,10 @@
     addStringOption(.CommandlineArguments, [.TargetSpecializable, .SupportsInheritKeyword])
     addStringOption(.EnvironmentVariables, [.TargetSpecializable, .SupportsInheritKeyword])
 
+    // List matches the available options for the 'C++ Language Dialect' setting in XCode 9.2.
+    let cppLanguageStandards = ["compiler-default", "c++98", "gnu++98", "c++0x", "gnu++0x", "c++14", "gnu++14", "c++17", "gnu++17"]
+    addStringEnumOption(.CLANG_CXX_LANGUAGE_STANDARD, .BuildSetting, "compiler-default",  cppLanguageStandards)
+
     addStringOption(.BuildActionPreActionScript, [.TargetSpecializable, .SupportsInheritKeyword])
     addStringOption(.LaunchActionPreActionScript, [.TargetSpecializable, .SupportsInheritKeyword])
     addStringOption(.TestActionPreActionScript, [.TargetSpecializable, .SupportsInheritKeyword])
diff --git a/src/TulsiGenerator/en.lproj/Options.strings b/src/TulsiGenerator/en.lproj/Options.strings
index ccd857b..e55a23f 100644
--- a/src/TulsiGenerator/en.lproj/Options.strings
+++ b/src/TulsiGenerator/en.lproj/Options.strings
@@ -34,6 +34,8 @@
 
 "ProjectPrioritizesSwift" = "Prioritize for Swift development instead of (Obj-)C(++)";
 "ProjectPrioritizesSwift_DESC" = "Tulsi uses this to try to improve Bazel caching; set this if you anticipate that most of your builds inside of the generated xcodeproj depend on Swift in some way. Setting this incorrectly won't break your builds but it will potentially make them slower.";
+"CLANG_CXX_LANGUAGE_STANDARD" = "C++ language standard";
+"CLANG_CXX_LANGUAGE_STANDARD_DESC" = "Sets the C++ language standard project wide to prevent any false live issue errors involving certain C++ features.";
 
 "CommandlineArguments" = "Commandline arguments";
 "EnvironmentVariables" = "Environment variables";
diff --git a/src/TulsiGeneratorTests/PBXTargetGeneratorTests.swift b/src/TulsiGeneratorTests/PBXTargetGeneratorTests.swift
index 25b3242..c6eeec0 100644
--- a/src/TulsiGeneratorTests/PBXTargetGeneratorTests.swift
+++ b/src/TulsiGeneratorTests/PBXTargetGeneratorTests.swift
@@ -199,6 +199,7 @@
 
     let topLevelBuildSettings = [
         "ALWAYS_SEARCH_USER_PATHS": "NO",
+        "CLANG_CXX_LANGUAGE_STANDARD": "compiler-default",
         "CLANG_ENABLE_OBJC_ARC": "YES",
         "CLANG_WARN_BOOL_CONVERSION": "YES",
         "CLANG_WARN_CONSTANT_CONVERSION": "YES",
@@ -249,6 +250,7 @@
 
     let topLevelBuildSettings = [
         "ALWAYS_SEARCH_USER_PATHS": "NO",
+        "CLANG_CXX_LANGUAGE_STANDARD": "compiler-default",
         "CLANG_ENABLE_OBJC_ARC": "YES",
         "CLANG_WARN_BOOL_CONVERSION": "YES",
         "CLANG_WARN_CONSTANT_CONVERSION": "YES",