testsuite: optimization dependent test

Kagamin spam at here.lot
Wed Mar 27 21:44:03 PDT 2013


Are you trying to get stack top?

void test(scope void delegate() dg)
{
   int[2] top;
   void* p=top.ptr;
   assert(p < dg.ptr);
   assert(dg.ptr !is null);
   //also check that ptr is not in heap
   assert(gc_addrOf(dg.ptr) is null);
}


More information about the D.gnu mailing list