Mercurial > projects > dstress
view nocompile/n/nested_class_04_D.d @ 1617:2c10afcfcf76
Move run/n/nested_class_04_{C,D} to nocompile. See DMD bug 80.
author | Christian Kamm <kamm incasoftware de> |
---|---|
date | Thu, 23 Jul 2009 19:49:42 +0200 |
parents | run/n/nested_class_04_D.d@81222734adf3 |
children |
line wrap: on
line source
// $HeadURL$ // $Date$ // $Author$ // @author@ <jarrett.billingsley@gmail.com> // @date@ 2006-04-02 // @uri@ http://d.puremagic.com/issues/show_bug.cgi?id=80 module dstress.run.n.nested_class_04_D; struct Outer{ int i; class Inner{ int x; this(){ x = i; } } Inner test(){ Inner o; o = new Inner(); return o; } } int main(){ Outer* outer = new Outer(); outer.i = 1; Outer.Inner inner = outer.test(); outer.i = 2; if(inner.x != 1){ assert(0); } return 0; }