[clang] [clang-repl] Fix crashing on unusable top-level declarations (PR #230054)
via cfe-commits
cfe-commits at lists.llvm.org
Thu Oct 8 04:23:00 PDT 2026
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff origin/main HEAD --extensions cpp -- clang/lib/Parse/ParseDecl.cpp clang/unittests/Interpreter/InterpreterTest.cpp --diff_from_common_commit
``````````
:warning:
The reproduction instructions above might return results for more than one PR
in a stack if you are using a stacked PR workflow. You can limit the results by
changing `origin/main` to the base branch/commit you want to compare against.
:warning:
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/clang/unittests/Interpreter/InterpreterTest.cpp b/clang/unittests/Interpreter/InterpreterTest.cpp
index 0411286c0..99e718e74 100644
--- a/clang/unittests/Interpreter/InterpreterTest.cpp
+++ b/clang/unittests/Interpreter/InterpreterTest.cpp
@@ -609,7 +609,7 @@ TEST_F(InterpreterTest, UnusableTopLevelDecl) {
ASSERT_EQ(V.getKind(), Value::K_Unspecified);
EXPECT_FALSE(V.isManuallyAlloc());
-TEST_F(InterpreterTest, EmscriptenExceptionHandling) {
+ TEST_F(InterpreterTest, EmscriptenExceptionHandling) {
#ifndef __EMSCRIPTEN__
GTEST_SKIP() << "This test only applies to Emscripten builds.";
#endif
``````````
</details>
https://github.com/llvm/llvm-project/pull/230054
More information about the cfe-commits
mailing list