X-Git-Url: https://oss.titaniummirror.com/gitweb/?a=blobdiff_plain;f=gcc%2Ftestsuite%2Fg%2B%2B.old-deja%2Fg%2B%2B.other%2Fbadopt1.C;fp=gcc%2Ftestsuite%2Fg%2B%2B.old-deja%2Fg%2B%2B.other%2Fbadopt1.C;h=0000000000000000000000000000000000000000;hb=6fed43773c9b0ce596dca5686f37ac3fc0fa11c0;hp=eefa00e78ebb81c86e34c198af3799654cfe10a8;hpb=27b11d56b743098deb193d510b337ba22dc52e5c;p=msp430-gcc.git diff --git a/gcc/testsuite/g++.old-deja/g++.other/badopt1.C b/gcc/testsuite/g++.old-deja/g++.other/badopt1.C deleted file mode 100644 index eefa00e7..00000000 --- a/gcc/testsuite/g++.old-deja/g++.other/badopt1.C +++ /dev/null @@ -1,15 +0,0 @@ -// Based on a testcase by Bryan Weston -// egcs 1.1 fails to increment count - -// Special g++ Options: -O2 - -struct Base { Base() {} }; // removing the constructor fixes the problem -struct Derived : Base {}; // so does removing the base class - -int main() { - int count = 0; - Derived* array[1]; // making this Base*[1] does not fix the problem - array[count++] = new Derived (); // but then new Base() does - if (count!=1) - return 1; -}