[clang] [Clang] Add flags and lang option for C++2d (PR #203992)

Corentin Jabot via cfe-commits cfe-commits at lists.llvm.org
Tue Jun 16 06:21:01 PDT 2026


================
@@ -228,7 +228,10 @@ static void addVisualCDefines(const LangOptions &Opts, MacroBuilder &Builder) {
       Builder.defineMacro("_HAS_CHAR16_T_LANGUAGE_SUPPORT", Twine(1));
 
     if (Opts.isCompatibleWithMSVC(LangOptions::MSVC2015)) {
-      if (Opts.CPlusPlus26)
+      if (Opts.CPlusPlus29)
+        // TODO update to the proper value.
+        Builder.defineMacro("_MSVC_LANG", "202700L");
----------------
cor3ntin wrote:

Right, can we just not do anything for MSVC? 
They won;t get to c++29 any time soon anyway

https://github.com/llvm/llvm-project/pull/203992


More information about the cfe-commits mailing list