view nocompile/debug_info_02.d @ 1330:f3f715978184

Georg Wrede <georg@iki.fi> 2007-01-07 mail:45A120F5.1050108@iki.fi
author thomask
date Sat, 13 Jan 2007 10:33:49 +0000
parents 0ea4c218a3ee
children b8c0195059d9
line wrap: on
line source

// $HeadURL$
// $Date$
// $Author$

// @author@	Regan Heath <regan@netwin.co.nz>
// @date@	2005-03-25
// @uri@	news:opsn61vgpg23k2f5@nrage.netwin.co.nz

// __DSTRESS_ELINE__ 13

module dstress.nocompile.debug_info_02;

typedef fn function() fn;

byte status;

fn foo() {
	status++;
	return &foo;
}

int main(){
	assert(status==0);
	fn p = foo();
	assert(status==1);
	p();
	assert(status==2);
	return 0;
}