From 60d5526d528565e697f4a1d9358f32fcd7952f06 Mon Sep 17 00:00:00 2001 From: Dennis Felsing Date: Fri, 9 Oct 2026 07:46:06 +0200 Subject: [PATCH] Support Clang 23 --- generator/annotator.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/generator/annotator.cpp b/generator/annotator.cpp index 7f3fd38..c052cb6 100644 --- a/generator/annotator.cpp +++ b/generator/annotator.cpp @@ -1012,7 +1012,12 @@ static std::string getQualifiedName(clang::NamedDecl *decl) std::string name; clang::PrintingPolicy policy(decl->getASTContext().getLangOpts()); // we don't want filelocation:line:column +#if CLANG_VERSION_MAJOR >= 23 + policy.AnonymousTagNameStyle = + llvm::to_underlying(clang::PrintingPolicy::AnonymousTagMode::Plain); +#else policy.AnonymousTagLocations = false; +#endif llvm::raw_string_ostream stream(name); decl->printQualifiedName(stream, policy); return name;