diff options
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.pt/union1.C')
-rw-r--r-- | gcc/testsuite/g++.old-deja/g++.pt/union1.C | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.pt/union1.C b/gcc/testsuite/g++.old-deja/g++.pt/union1.C new file mode 100644 index 000000000..6f17cf18d --- /dev/null +++ b/gcc/testsuite/g++.old-deja/g++.pt/union1.C @@ -0,0 +1,18 @@ +// { dg-do assemble } + +union Un {int i;}; + +template<class T1, class T2> struct St1 {}; +template<class T> struct St1<Un,T> {}; + +template<class T> struct St2 {}; +template<> struct St2<Un> {}; + +template<class T1, class T2> struct St3 {}; +template<> struct St3<Un,int> {}; + +void f() { + St1<int,int> s1; + St2<int> s2; + St3<int,int> s3; +} |