[clang] [clang][driver] Suppress gnu-line-marker when saving temps (PR #134621)

2025-06-12 Thread Fangrui Song via cfe-commits
https://github.com/MaskRay commented: LGTM! https://github.com/llvm/llvm-project/pull/134621 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][driver] Suppress gnu-line-marker when saving temps (PR #134621)

2025-06-10 Thread via cfe-commits
https://github.com/macurtis-amd closed https://github.com/llvm/llvm-project/pull/134621 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][driver] Suppress gnu-line-marker when saving temps (PR #134621)

2025-06-09 Thread via cfe-commits
macurtis-amd wrote: @MaskRay I plan on merging this tomorrow morning unless you have any objections. https://github.com/llvm/llvm-project/pull/134621 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinf

[clang] [clang][driver] Suppress gnu-line-marker when saving temps (PR #134621)

2025-06-09 Thread via cfe-commits
https://github.com/macurtis-amd updated https://github.com/llvm/llvm-project/pull/134621 >From d78c113c285b3037e3cc15d2ae3f9769265d0d0e Mon Sep 17 00:00:00 2001 From: Matthew Curtis Date: Mon, 9 Jun 2025 06:57:35 -0500 Subject: [PATCH 1/2] [clang] Suppress gnu-line-marker when saving temps Whe

[clang] [clang][driver] Suppress gnu-line-marker when saving temps (PR #134621)

2025-04-28 Thread via cfe-commits
macurtis-amd wrote: @MaskRay ping https://github.com/llvm/llvm-project/pull/134621 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][driver] Suppress gnu-line-marker when saving temps (PR #134621)

2025-04-21 Thread via cfe-commits
macurtis-amd wrote: @MaskRay Any other concerns with this change? https://github.com/llvm/llvm-project/pull/134621 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][driver] Suppress gnu-line-marker when saving temps (PR #134621)

2025-04-21 Thread via cfe-commits
@@ -0,0 +1,9 @@ +// RUN: %clang_cc1 -std=c99 -fsyntax-only -pedantic %s 2>&1 | grep 'warning: this style of line directive is a GNU extension' macurtis-amd wrote: Updated test to use FileCheck. https://github.com/llvm/llvm-project/pull/134621 __

[clang] [clang][driver] Suppress gnu-line-marker when saving temps (PR #134621)

2025-04-21 Thread via cfe-commits
https://github.com/macurtis-amd updated https://github.com/llvm/llvm-project/pull/134621 >From 9d38a08bc91273d961fa1bd855d212b09249d826 Mon Sep 17 00:00:00 2001 From: Matthew Curtis Date: Fri, 18 Apr 2025 12:46:23 -0500 Subject: [PATCH 1/2] [clang] Suppress gnu-line-marker when saving temps Wh

[clang] [clang][driver] Suppress gnu-line-marker when saving temps (PR #134621)

2025-04-18 Thread Fangrui Song via cfe-commits
@@ -0,0 +1,9 @@ +// RUN: %clang_cc1 -std=c99 -fsyntax-only -pedantic %s 2>&1 | grep 'warning: this style of line directive is a GNU extension' MaskRay wrote: We prefer `FileCheck` to `grep`. FileCheck enables testing the line number, e.g. ``` // CHECK: [[#@LINE

[clang] [clang][driver] Suppress gnu-line-marker when saving temps (PR #134621)

2025-04-18 Thread via cfe-commits
macurtis-amd wrote: @MaskRay Latest revision moves the suppression out of the Driver and into the Frontend. Behavior matches gcc. https://github.com/llvm/llvm-project/pull/134621 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.ll

[clang] [clang][driver] Suppress gnu-line-marker when saving temps (PR #134621)

2025-04-18 Thread via cfe-commits
https://github.com/macurtis-amd updated https://github.com/llvm/llvm-project/pull/134621 >From 9d38a08bc91273d961fa1bd855d212b09249d826 Mon Sep 17 00:00:00 2001 From: Matthew Curtis Date: Fri, 18 Apr 2025 12:46:23 -0500 Subject: [PATCH] [clang] Suppress gnu-line-marker when saving temps When p

[clang] [clang][driver] Suppress gnu-line-marker when saving temps (PR #134621)

2025-04-14 Thread via cfe-commits
macurtis-amd wrote: > I don't, but I wonder what's the GCC behavior. It seems to suppress the > diagnostic when processing a .i file. Diagnostic seems to be suppressed by [-fpreprocessed](https://gcc.gnu.org/onlinedocs/gcc/Preprocessor-Options.html#index-fpreprocessed), which is implicit if y

[clang] [clang][driver] Suppress gnu-line-marker when saving temps (PR #134621)

2025-04-11 Thread Fangrui Song via cfe-commits
MaskRay wrote: I don't, but I wonder what's the GCC behavior. It seems to suppress the diagnostic when processing a .i file. https://github.com/llvm/llvm-project/pull/134621 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.or

[clang] [clang][driver] Suppress gnu-line-marker when saving temps (PR #134621)

2025-04-10 Thread Fangrui Song via cfe-commits
MaskRay wrote: I am not sure clang driver should does this unusual suppression. You'd also get a warning with: `clang test.c -E -Wall -pedantic; clang test.i -S -Wall -pedantic` There might be a different strategy to suppress this diagnostic? https://github.com/llvm/llvm-project/pull/134621

[clang] [clang][driver] Suppress gnu-line-marker when saving temps (PR #134621)

2025-04-07 Thread via cfe-commits
macurtis-amd wrote: > I am not sure clang driver should does this unusual suppression. > > You'd also get a warning with: `clang test.c -E -Wall -pedantic; clang test.i > -S -Wall -pedantic` > > There might be a different strategy to suppress this diagnostic? Did you have an alternative in mi

[clang] [clang][driver] Suppress gnu-line-marker when saving temps (PR #134621)

2025-04-07 Thread via cfe-commits
https://github.com/macurtis-amd updated https://github.com/llvm/llvm-project/pull/134621 >From 2f2396511137feb21446b93dc344cd82a245627f Mon Sep 17 00:00:00 2001 From: Matthew Curtis Date: Sat, 5 Apr 2025 04:34:03 -0500 Subject: [PATCH] [clang][driver] Suppress gnu-line-marker when saving temps

[clang] [clang][driver] Suppress gnu-line-marker when saving temps (PR #134621)

2025-04-07 Thread via cfe-commits
https://github.com/macurtis-amd created https://github.com/llvm/llvm-project/pull/134621 When passing `-save-temps` to clang, the generated preprocessed output uses gnu line markers. This unexpectedly triggers gnu-line-marker warnings when used with `-Weverything` or `-pedantic`. Even worse, c

[clang] [clang][driver] Suppress gnu-line-marker when saving temps (PR #134621)

2025-04-07 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (macurtis-amd) Changes When passing `-save-temps` to clang, the generated preprocessed output uses gnu line markers. This unexpectedly triggers gnu-line-marker warnings when used with `-Weverything` or `-pedantic`. Even worse, compil