================
@@ -6316,6 +6310,15 @@ TEST(HasAnyTemplateArgumentLoc, 
BindsToSpecializationWithDoubleArgument) {
                       hasTypeLoc(loc(asString("double")))))))))));
 }
 
+TEST(HasAnyTemplateArgumentLoc, BindsToExplicitSpecializationWithIntArgument) {
+  EXPECT_TRUE(
+      matches("template<typename T> class A {}; template<> class A<int> {};",
+              classTemplateSpecializationDecl(
+                  hasName("A"), hasAnyTemplateArgument(templateArgument(
+                                    refersToType(asString("int")))))));
+}
+
+#if 0
----------------
sdkrystian wrote:

Oh, hah. I was checking whether we could still match class template 
specializations based on template arguments. The commented out tests should be 
replaced with equivalents written using the above syntax (where it makes sense).

So to answer your question, it's from local testing :)

https://github.com/llvm/llvm-project/pull/81642
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to