[clang] [clang][AST] fix ast-print of `extern <lang>` with >=2 declarators (PR #93131)

Artem Yurchenko via cfe-commits cfe-commits at lists.llvm.org
Thu May 23 09:16:18 PDT 2024


================
@@ -1145,13 +1145,15 @@ void DeclPrinter::VisitLinkageSpecDecl(LinkageSpecDecl *D) {
     l = "C++";
   }
 
+  bool HasMoreThanOneDecl =
+      *D->decls_begin() && D->decls_begin()->getNextDeclInContext();
----------------
temyurchenko wrote:

Sure!

For my own education though, I'd like to know the reasoning, just to be able to make the right decision in future situations.

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


More information about the cfe-commits mailing list