clc: Fix createDiagnostics for LLVM-22

Cc: mesa-stable
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13986
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com>
Reviewed-by: Mary Guillemard <mary@mary.zone>
Reviewed-by: Janne Grunau <j@jannau.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37690>
(cherry picked from commit 1db77d08e2)
This commit is contained in:
Karol Herbst 2025-10-03 19:19:20 +02:00 committed by Eric Engestrom
parent 7a87cc5299
commit cea965eee5
2 changed files with 2 additions and 2 deletions

View file

@ -5434,7 +5434,7 @@
"description": "clc: Fix createDiagnostics for LLVM-22",
"nominated": true,
"nomination_type": 1,
"resolution": 0,
"resolution": 1,
"main_sha": null,
"because_sha": null,
"notes": null

View file

@ -866,7 +866,7 @@ clc_compile_to_llvm_module(LLVMContext &llvm_ctx,
c->getDiagnosticOpts().ShowCarets = false;
c->createDiagnostics(
#if LLVM_VERSION_MAJOR >= 20
#if LLVM_VERSION_MAJOR >= 20 && LLVM_VERSION_MAJOR < 22
*llvm::vfs::getRealFileSystem(),
#endif
new clang::TextDiagnosticPrinter(