[clang] [clang] Fix incorrect line numbers with -E and raw string (#47577) (PR #77021)

2024-09-11 Thread Steve Cornett via cfe-commits
https://github.com/stevecor closed https://github.com/llvm/llvm-project/pull/77021 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix incorrect line numbers with -E and raw string (#47577) (PR #77021)

2024-04-01 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman commented: Thank you for this! The functional changes look good to me, but it might make sense to rename the test (or add comments) to make it more clear what's being tested and why, and we should have a release note so users know about the fix. https://github.

[clang] [clang] Fix incorrect line numbers with -E and raw string (#47577) (PR #77021)

2024-04-01 Thread Aaron Ballman via cfe-commits
@@ -0,0 +1,6 @@ +// RUN: %clang_cc1 -E %s | FileCheck %s +// CHECK: AAA +// CHECK-NEXT: BBB +R"( +AAA)" +BBB AaronBallman wrote: Thanks for the explanation! Perhaps a better name for the test file is `raw_string_print.cpp` or something along those lines, so nobo

[clang] [clang] Fix incorrect line numbers with -E and raw string (#47577) (PR #77021)

2024-04-01 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman edited https://github.com/llvm/llvm-project/pull/77021 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix incorrect line numbers with -E and raw string (#47577) (PR #77021)

2024-04-01 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: > > This will need a release note > > Are you asking me to do this? I did not see any instructions about how to do > this. Sorry for not seeing this question earlier! Yes, you should add a release note to clang/docs/ReleaseNotes.rst; we have a section for bug fixes: https

[clang] [clang] Fix incorrect line numbers with -E and raw string (#47577) (PR #77021)

2024-03-29 Thread Steve Cornett via cfe-commits
stevecor wrote: Ping https://github.com/llvm/llvm-project/pull/77021 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix incorrect line numbers with -E and raw string (#47577) (PR #77021)

2024-03-11 Thread Steve Cornett via cfe-commits
stevecor wrote: Ping https://github.com/llvm/llvm-project/pull/77021 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix incorrect line numbers with -E and raw string (#47577) (PR #77021)

2024-02-09 Thread Steve Cornett via cfe-commits
stevecor wrote: > This will need a release note Are you asking me to do this? I did not see any instructions about how to do this. https://github.com/llvm/llvm-project/pull/77021 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.l

[clang] [clang] Fix incorrect line numbers with -E and raw string (#47577) (PR #77021)

2024-02-09 Thread Steve Cornett via cfe-commits
@@ -0,0 +1,6 @@ +// RUN: %clang_cc1 -E %s | FileCheck %s +// CHECK: AAA +// CHECK-NEXT: BBB +R"( +AAA)" +BBB stevecor wrote: This test demonstrates that the line `AAA` is followed immediately by the line `BBB` with no intervening blank line. Without the fix, the

[clang] [clang] Fix incorrect line numbers with -E and raw string (#47577) (PR #77021)

2024-02-07 Thread via cfe-commits
@@ -0,0 +1,6 @@ +// RUN: %clang_cc1 -E %s | FileCheck %s +// CHECK: AAA +// CHECK-NEXT: BBB +R"( +AAA)" +BBB cor3ntin wrote: This test is not testing line numbers https://github.com/llvm/llvm-project/pull/77021 ___ cfe

[clang] [clang] Fix incorrect line numbers with -E and raw string (#47577) (PR #77021)

2024-02-07 Thread via cfe-commits
https://github.com/cor3ntin edited https://github.com/llvm/llvm-project/pull/77021 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix incorrect line numbers with -E and raw string (#47577) (PR #77021)

2024-02-07 Thread via cfe-commits
https://github.com/cor3ntin commented: Thanks for this patch. This will need a release note and I'm not sure the test checks what you want. The change itself looks good https://github.com/llvm/llvm-project/pull/77021 ___ cfe-commits mailing list cfe-

[clang] [clang] Fix incorrect line numbers with -E and raw string (#47577) (PR #77021)

2024-02-07 Thread Steve Cornett via cfe-commits
stevecor wrote: Ping https://github.com/llvm/llvm-project/pull/77021 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix incorrect line numbers with -E and raw string (#47577) (PR #77021)

2024-01-31 Thread Steve Cornett via cfe-commits
stevecor wrote: Ping https://github.com/llvm/llvm-project/pull/77021 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix incorrect line numbers with -E and raw string (#47577) (PR #77021)

2024-01-04 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Steve Cornett (stevecor) Changes When printing preprocessed tokens, handle newlines in string literals because raw string literals may contain newlines. --- Full diff: https://github.com/llvm/llvm-project/pull/77021.diff 2 Files Affecte

[clang] [clang] Fix incorrect line numbers with -E and raw string (#47577) (PR #77021)

2024-01-04 Thread via cfe-commits
github-actions[bot] wrote: Thank you for submitting a Pull Request (PR) to the LLVM Project! This PR will be automatically labeled and the relevant teams will be notified. If you wish to, you can add reviewers by using the "Reviewers" section on this page. If this is not working for you, it i

[clang] [clang] Fix incorrect line numbers with -E and raw string (#47577) (PR #77021)

2024-01-04 Thread Steve Cornett via cfe-commits
https://github.com/stevecor created https://github.com/llvm/llvm-project/pull/77021 When printing preprocessed tokens, handle newlines in string literals because raw string literals may contain newlines. >From 47aa72d5e68c08657a519c3d0a3a73fbd1c89372 Mon Sep 17 00:00:00 2001 From: Steve Cornet