aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaolo Carlini <paolo.carlini@oracle.com>2016-06-05 15:08:22 +0000
committerPaolo Carlini <paolo@gcc.gnu.org>2016-06-05 15:08:22 +0000
commitc1c009833d16ef31784ab6df078722d178758e43 (patch)
treedbf398085b4decf9406218231abbc2af3b43b33b
parent16e396885a672b84bb61f6d00c4117f9c2ba11ca (diff)
downloadgcc-c1c009833d16ef31784ab6df078722d178758e43.zip
gcc-c1c009833d16ef31784ab6df078722d178758e43.tar.gz
gcc-c1c009833d16ef31784ab6df078722d178758e43.tar.bz2
re PR c++/49377 (Template specialization attributes cause type mismatches when used)
2016-06-05 Paolo Carlini <paolo.carlini@oracle.com> PR c++/49377 * g++.dg/template/pr49377.C: New. From-SVN: r237098
-rw-r--r--gcc/testsuite/ChangeLog5
-rw-r--r--gcc/testsuite/g++.dg/template/pr49377.C16
2 files changed, 21 insertions, 0 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index c272ade..f327b82 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2016-06-05 Paolo Carlini <paolo.carlini@oracle.com>
+
+ PR c++/49377
+ * g++.dg/template/pr49377.C: New.
+
2016-06-04 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/71405
diff --git a/gcc/testsuite/g++.dg/template/pr49377.C b/gcc/testsuite/g++.dg/template/pr49377.C
new file mode 100644
index 0000000..cb4287a
--- /dev/null
+++ b/gcc/testsuite/g++.dg/template/pr49377.C
@@ -0,0 +1,16 @@
+// PR c++/49377
+
+template <typename T, int N> class v;
+
+template <typename T> class v<T,2> {
+ v() { };
+} __attribute__((__may_alias__));
+
+typedef v<float,2> float2;
+
+class a {
+ void f(float2 &point);
+ float2 d;
+};
+
+void a::f(float2 &point) { }