================ @@ -4988,6 +4988,39 @@ TEST_P(ASTImporterOptionSpecificTestBase, } } +TEST_P(ImportFriendClasses, RecordVarTemplateDecl) { + Decl *ToTU = getToTuDecl( + R"( + template <class T> + class A { + public: + template <class U> + static constexpr bool X = true; + }; + )", + Lang_CXX14); + + auto *Fwd = FirstDeclMatcher<VarTemplateDecl>().match( + ToTU, varTemplateDecl(hasName("X"))); + Decl *FromTU = getTuDecl( + R"( + template <class T> + class A { + public: + template <class U> + static constexpr bool X = true; + }; + )", + Lang_CXX14, "input1.cc"); + auto *FromA = FirstDeclMatcher<VarTemplateDecl>().match( ---------------- balazske wrote:
`FromA` and `ToA` looks again not correct, these should be `FromX` and `ToX`. https://github.com/llvm/llvm-project/pull/67522 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits