[clang] [clang][ASTImporter] Fix unused variable warning (NFC) (PR #122686)

via cfe-commits cfe-commits at lists.llvm.org
Mon Jan 13 02:35:51 PST 2025


llvmbot wrote:


<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-clang

Author: Balázs Kéri (balazske)

<details>
<summary>Changes</summary>



---
Full diff: https://github.com/llvm/llvm-project/pull/122686.diff


1 Files Affected:

- (modified) clang/unittests/AST/ASTImporterTest.cpp (+2-2) 


``````````diff
diff --git a/clang/unittests/AST/ASTImporterTest.cpp b/clang/unittests/AST/ASTImporterTest.cpp
index a0aaad6082d8cb..791248e7a394f1 100644
--- a/clang/unittests/AST/ASTImporterTest.cpp
+++ b/clang/unittests/AST/ASTImporterTest.cpp
@@ -10182,7 +10182,7 @@ TEST_P(ASTImporterOptionSpecificTestBase, ImportIntoReopenedNamespaceNoMatch1) {
         struct X { int A; };
       }
       )";
-  Decl *ToTU = getToTuDecl(ToCode, Lang_CXX11);
+  getToTuDecl(ToCode, Lang_CXX11);
   const char *Code =
       R"(
       namespace a {
@@ -10205,7 +10205,7 @@ TEST_P(ASTImporterOptionSpecificTestBase, ImportIntoReopenedNamespaceNoMatch2) {
       namespace a {
       }
       )";
-  Decl *ToTU = getToTuDecl(ToCode, Lang_CXX11);
+  getToTuDecl(ToCode, Lang_CXX11);
   const char *Code =
       R"(
       namespace a {

``````````

</details>


https://github.com/llvm/llvm-project/pull/122686


More information about the cfe-commits mailing list