* cfgloopmanip.c (duplicate_loop_to_header_edge): Cleanup profile
[official-gcc.git] / gcc / testsuite / g++.old-deja / g++.law / operators27.C
blob5fb3a74cbfaab3f165ccd404c082bdb3789f7729
1 // { dg-do run  }
2 // GROUPS passed operators
3 // opr-new file
4 // From: David Binderman 3841 <dcb@us-es.sel.de>
5 // Date:     Mon, 21 Jun 93 11:42:11 +0200
6 // Subject:  G++ 2.4.3 and operator new
7 // Message-ID: <9306210942.AA10276@slsvitt.us-es.sel.de>
9 int FLAG=0;
11 #include <new>
13 extern "C" int printf( const char *, ...);
15 void * operator new(std::size_t, const std::nothrow_t&) throw()         { FLAG=1; return 0; }
17 class K {
18 private:
19         int i;
20 public:
21         K( int j) {
22                 i = j;
23         }
26 int main(void)
28     K * pK = new (std::nothrow) K( 10);
29     if ( FLAG != 1 )
30         { printf ("FAIL\n"); return 1; }
31     else
32         printf ("PASS\n");
33     return 0;