================
@@ -3957,7 +3958,12 @@ LangOptions getFormattingLangOpts(const FormatStyle 
&Style) {
   LangOpts.Digraphs = LexingStd >= FormatStyle::LS_Cpp11;
 
   LangOpts.LineComment = 1;
-  LangOpts.CXXOperatorNames = Style.isCpp();
+
+  const auto Language = Style.Language;
+  LangOpts.C17 = Language == FormatStyle::LK_C;
----------------
arichardson wrote:

Shouldn't `LangOpts.CPlusPlus` be false for C inputs? But I imagine that could 
require some additional changes

https://github.com/llvm/llvm-project/pull/128287
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to