https://github.com/AnonMiraj created https://github.com/llvm/llvm-project/pull/209355
`getShowColors() != ShowColorsKind::Off` is also true for the default Auto, so ordinary non-TTY compiles where colors are never actually emitted kept recording check points, leaving the original 718aac9f cost in place. >From e2a57c5ff2cbf653d478e1b3ec5404b584d6c3bb Mon Sep 17 00:00:00 2001 From: Anonmiraj <[email protected]> Date: Tue, 14 Jul 2026 04:59:50 +0300 Subject: [PATCH] [clang][Diagnostics] Fix check-point recording under default colors --- clang/lib/Lex/Preprocessor.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/clang/lib/Lex/Preprocessor.cpp b/clang/lib/Lex/Preprocessor.cpp index 5ee53a93732bb..427a3826b299a 100644 --- a/clang/lib/Lex/Preprocessor.cpp +++ b/clang/lib/Lex/Preprocessor.cpp @@ -103,8 +103,7 @@ Preprocessor::Preprocessor(const PreprocessorOptions &PPOpts, OwnsHeaderSearch = OwnsHeaders; // Only record check points if we might highlight diagnostic snippets. - RecordCheckPoints = getDiagnostics().getDiagnosticOptions().getShowColors() != - ShowColorsKind::Off; + RecordCheckPoints = getDiagnostics().getShowColors(); // Default to discarding comments. KeepComments = false; _______________________________________________ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
