[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-05 Thread Aaron Ballman via cfe-commits
@@ -1349,7 +1349,7 @@ void TextDiagnostic::emitSnippetAndCaret( // Prepare source highlighting information for the lines we're about to // emit, starting from the first line. std::unique_ptr[]> SourceStyles = - highlightLines(BufStart, Lines.first, Lines.second, PP,

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
@@ -1349,7 +1349,7 @@ void TextDiagnostic::emitSnippetAndCaret( // Prepare source highlighting information for the lines we're about to // emit, starting from the first line. std::unique_ptr[]> SourceStyles = - highlightLines(BufStart, Lines.first, Lines.second, PP,

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
@@ -1349,7 +1349,7 @@ void TextDiagnostic::emitSnippetAndCaret( // Prepare source highlighting information for the lines we're about to // emit, starting from the first line. std::unique_ptr[]> SourceStyles = - highlightLines(BufStart, Lines.first, Lines.second, PP,

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
@@ -1349,7 +1349,7 @@ void TextDiagnostic::emitSnippetAndCaret( // Prepare source highlighting information for the lines we're about to // emit, starting from the first line. std::unique_ptr[]> SourceStyles = - highlightLines(BufStart, Lines.first, Lines.second, PP,

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

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

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

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

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
@@ -1349,7 +1349,7 @@ void TextDiagnostic::emitSnippetAndCaret( // Prepare source highlighting information for the lines we're about to // emit, starting from the first line. std::unique_ptr[]> SourceStyles = - highlightLines(BufStart, Lines.first, Lines.second, PP,

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
@@ -1349,7 +1349,7 @@ void TextDiagnostic::emitSnippetAndCaret( // Prepare source highlighting information for the lines we're about to // emit, starting from the first line. std::unique_ptr[]> SourceStyles = - highlightLines(BufStart, Lines.first, Lines.second, PP,

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
https://github.com/alexfh closed https://github.com/llvm/llvm-project/pull/80442 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
@@ -1349,7 +1349,7 @@ void TextDiagnostic::emitSnippetAndCaret( // Prepare source highlighting information for the lines we're about to // emit, starting from the first line. std::unique_ptr[]> SourceStyles = - highlightLines(BufStart, Lines.first, Lines.second, PP,

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
@@ -1349,7 +1349,7 @@ void TextDiagnostic::emitSnippetAndCaret( // Prepare source highlighting information for the lines we're about to // emit, starting from the first line. std::unique_ptr[]> SourceStyles = - highlightLines(BufStart, Lines.first, Lines.second, PP,

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman approved this pull request. LGTM to get this unblocked, but I would love it if we could add a test case post-commit. https://github.com/llvm/llvm-project/pull/80442 ___ cfe-commits mailing list

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread Aaron Ballman via cfe-commits
@@ -1349,7 +1349,7 @@ void TextDiagnostic::emitSnippetAndCaret( // Prepare source highlighting information for the lines we're about to // emit, starting from the first line. std::unique_ptr[]> SourceStyles = - highlightLines(BufStart, Lines.first, Lines.second, PP,

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread Erich Keane via cfe-commits
@@ -1349,7 +1349,7 @@ void TextDiagnostic::emitSnippetAndCaret( // Prepare source highlighting information for the lines we're about to // emit, starting from the first line. std::unique_ptr[]> SourceStyles = - highlightLines(BufStart, Lines.first, Lines.second, PP,

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. https://github.com/llvm/llvm-project/pull/80442 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread Erich Keane via cfe-commits
https://github.com/erichkeane edited https://github.com/llvm/llvm-project/pull/80442 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (alexfh) Changes Implements the fix proposed by Evgeny Eltsin on https://github.com/llvm/llvm-project/pull/66514#issuecomment-1924039038. No test case provided, since the bug is extremely sensitive to the preprocessor state (headers,

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
https://github.com/alexfh ready_for_review https://github.com/llvm/llvm-project/pull/80442 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix clang crash when printing highlighted code in diagnostic (after #66514) (PR #80442)

2024-02-02 Thread via cfe-commits
https://github.com/alexfh created https://github.com/llvm/llvm-project/pull/80442 Implements the fix proposed by Evgeny Eltsin on https://github.com/llvm/llvm-project/pull/66514#issuecomment-1924039038. No test case provided, since the bug is extremely sensitive to the preprocessor state