================
@@ -0,0 +1,15 @@
+// RUN: %clang_cc1 -fsyntax-only -verify %s
+
+template < class T, class V > struct A
+{
+    A ();
+    A (A &);
+    A (A < V,T >);
+    // expected-error@-1 {{copy constructor must pass its first argument by 
reference}}
+};
+
+void f ()
+{
+    A <int, int> (A < int, int >());
+    // expected-note@-1 {{in instantiation of template class 'A<int, int>' 
requested here}}
----------------
shafik wrote:

We should also test the case where the parameters are not the same, since that 
should not fail.

https://github.com/llvm/llvm-project/pull/81251
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to