Support LLVM/Clang 23 and test LLVM 21-23 in CI - #31
Merged
Conversation
parcollet
force-pushed
the
llvm-23-compat
branch
from
August 6, 2026 16:09
8bd1102 to
a062ffe
Compare
An explicit specialization is required to carry its template argument list "as written". A null worked by accident until LLVM 23.
- doc_string: ASTContext::getRawCommentForDeclNoCache was generalized to macros and renamed to getRawCommentNoCache (llvm/llvm-project#198452) - custom_action: DiagnosticOptions::ShowColors became a protected tri-state enum option reached via setShowColors (llvm/llvm-project#202441) Co-authored-by: Olivier Parcollet <oparcollet@flatironinstitute.org>
Ubuntu 24.04 only ships clang-20, so the newer releases are installed from the versioned apt.llvm.org suites (llvm-toolchain-noble-<N>). The llvm.sh helper is deliberately not used: it maps 23 to the unversioned "development" suite, which moves on to the next major version as soon as LLVM branches for a release and would then stop providing clang-23. The compiler is now derived from a single matrix.llvm key rather than being repeated in cc / cxx, so a version bump can no longer install the packages of one LLVM version while compiling with another -- which would silently test the wrong toolchain, since clang_detection.cmake locates LLVM through the compiler's resource dir. macos keeps explicit cc / cxx because brew's llvm provides the unversioned clang. The ccache keys move from matrix.cc to the same fallback so that the four ubuntu jobs do not share one cache. Assisted-by: Claude <noreply@anthropic.com>
The macos-14 runners have long queue waits. Follow app4triqs (d14ce18) and move to the GA macos-26 image. Assisted-by: Claude <noreply@anthropic.com>
Wentzell
force-pushed
the
llvm-23-compat
branch
from
August 6, 2026 19:10
a2f6a61 to
9854f09
Compare
- actions/checkout v4 -> v7 - actions/cache/restore and /save v4 -> v6 Assisted-by: Claude <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds LLVM/Clang 23 support and extends the CI matrix to LLVM 21, 22 and 23.
LLVM 23 API changes
doc_string:getRawCommentForDeclNoCachewas generalized to macros and renamedgetRawCommentNoCache(Associate documentation comments with macro definitions llvm/llvm-project#198452).custom_action:DiagnosticOptions::ShowColorsis now a protected tri-state option set viasetShowColors([Clang] Refactor and consolidate color diagnostic handling llvm/llvm-project#202441).inject_bool_vartempl_specialization: the synthesizedis_wrapped<T>specialization now carries its template argument list as written. [Clang][RAV] Simplify TraverseTemplateArgumentLocsHelper llvm/llvm-project#199131 made that dereference unconditional, so the missing list segfaulted every matcher traversal.The guards keep the LLVM >= 20 support range intact.
CI matrix
Ubuntu 24.04 only ships
clang-20, so LLVM 21-23 come from the versionedapt.llvm.orgsuites rather thanllvm.sh, whose unversioned suite stops providingclang-23once LLVM branches for release. The compiler is derived from a singlematrix.llvmkey so a bump cannot install one version's packages while compiling with another.Built and tested in
ubuntu:24.04containers: LLVM 21 and 22 pass 44/44, LLVM 23 passes 38/38 (against an older c2py).noble-23carries dailyrelease/23.xsnapshots, so that job can fail on a bad snapshot;fail-fast: falsekeeps it isolated.