Mercurial > projects > dstress
annotate norun/delete_03.d @ 1630:d0efa3ae5522 default tip
run/mini/naked_asm5: New x86_64 ABI passes the arguments in reverse order.
author | David Nadlinger <code@klickverbot.at> |
---|---|
date | Sat, 23 Apr 2011 22:57:32 +0200 |
parents | fbee62becd2c |
children |
rev | line source |
---|---|
379 | 1 // $HeadURL$ |
2 // $Date$ | |
3 // $Author$ | |
4 | |
392 | 5 // @WARNING@ direct access to Phobos's GC |
6 | |
7 // __DSTRESS_ELINE__ 15 | |
379 | 8 |
9 module dstress.run.delete_03; | |
10 | |
392 | 11 import std.gc; |
12 | |
379 | 13 struct MyStruct{ |
14 delete(void* p){ | |
15 assert(0); | |
16 } | |
17 } | |
18 | |
392 | 19 void test(){ |
697 | 20 MyStruct* t = new MyStruct(); |
21 assert(t); | |
392 | 22 } |
23 | |
379 | 24 int main(){ |
392 | 25 test(); |
26 std.gc.fullCollect(); | |
27 std.gc.minimize(); | |
379 | 28 return 0; |
29 } |