diff options
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.law/bad-error6.C')
-rw-r--r-- | gcc/testsuite/g++.old-deja/g++.law/bad-error6.C | 27 |
1 files changed, 1 insertions, 26 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.law/bad-error6.C b/gcc/testsuite/g++.old-deja/g++.law/bad-error6.C index a58a5fad2e4..a1bf1a8b294 100644 --- a/gcc/testsuite/g++.old-deja/g++.law/bad-error6.C +++ b/gcc/testsuite/g++.old-deja/g++.law/bad-error6.C @@ -1,26 +1 @@ -// Build don't link: -// GROUPS passed bad-errors -typedef unsigned long size_t; - -class tt { - public: - tt(int); - - private: - void *operator new(size_t a); // Forbid object creation in heap memory. -}; - -void st(const tt&, int); - -void ff(int i, int j) -{ - if( i > 0 ) { - // This work ok. - tt a_tt(i); - st(a_tt, j); - } - else { - // This triggers an error because of private operator new ????. - st(tt(-i), j); - } -} +typedef __SIZE_TYPE__ size_t; |