From: Nathan Sidwell Date: Tue, 3 Aug 1999 14:46:14 +0000 (+0000) Subject: * g++.old-deja/g++.other/struct1.C: New test. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=4a30151d102fe111f5de787992494970248ae246;p=gcc.git * g++.old-deja/g++.other/struct1.C: New test. From-SVN: r28474 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 885df45b760..429cb89ae56 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,7 @@ +1999-08-03 Nathan Sidwell + + * g++.old-deja/g++.other/struct1.C: New test. + 1999-08-03 Nathan Sidwell * g++.old-deja/g++.other/enum2.C: New test. diff --git a/gcc/testsuite/g++.old-deja/g++.other/struct1.C b/gcc/testsuite/g++.old-deja/g++.other/struct1.C new file mode 100644 index 00000000000..4f1c52ab092 --- /dev/null +++ b/gcc/testsuite/g++.old-deja/g++.other/struct1.C @@ -0,0 +1,42 @@ +// Build don't link: + +// Copyright (C) 1999 Free Software Foundation, Inc. +// Contributed by Nathan Sidwell 3 Jun 1999 + +// Duplicate definitions are wrong, we should just cough +// politely, but we used to die horribly. + +class Y +{ // ERROR - previous definition +}; +class Y +{ // ERROR - redefinition +}; + +template class X +{ // ERROR - previous definition +}; +template class X +{ // ERROR - redefinition +}; + +template class X +{ // ERROR - previous definition +}; +template class X +{ // ERROR - redefinition +}; + +template<> class X +{ // ERROR - previous definition +}; +template<> class X +{ // ERROR - redefinition +}; + +template<> class X +{ // ERROR - previous definition +}; +template<> class X +{ // ERROR - redefinition +};