]>
git.saurik.com Git - apple/dyld.git/blob - unit-tests/test-cases/operator-new-dylib/main.cxx
1 #include <stdio.h> // fprintf(), NULL
2 #include <stdlib.h> // exit(), EXIT_SUCCESS
4 #include "test.h" // PASS(), FAIL(), XPASS(), XFAIL()
12 static char all
[] = "hello";
14 void* operator new[](std::size_t) throw (std::bad_alloc
)
22 char* newArray
= new char[24];
23 char* fromFoo
= foo();
25 if ( fromFoo
== newArray
)
26 PASS("operator-new-dylib");
28 FAIL("operator-new-dylib");