Mercurial > projects > dstress
changeset 1038:c35b15527bc1
"Internal error: e2ir.c 736" on valid code
<h3r3tic@mat.uni.torun.pl>
2006-06-01
news:bug-172-3@http.d.puremagic.com/bugzilla/
author | thomask |
---|---|
date | Fri, 02 Jun 2006 16:56:21 +0000 |
parents | 22f348c04a9b |
children | 4a026c7451a0 |
files | run/b/bug_e2ir_736_A.d run/b/bug_e2ir_736_B.d run/b/bug_e2ir_736_C.d run/b/bug_e2ir_736_D.d |
diffstat | 4 files changed, 133 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/run/b/bug_e2ir_736_A.d Fri Jun 02 16:56:21 2006 +0000 @@ -0,0 +1,34 @@ +// $HeadURL$ +// $Date$ +// $Author$ + +// @author@ <h3r3tic@mat.uni.torun.pl> +// @date@ 2006-06-01 +// @uri@ news:bug-172-3@http.d.puremagic.com/bugzilla/ + +module dstress.run.b.bug_e2ir_736_A; + +int status; + +template Foo(){ + template func() { + int func() { + return status; + } + } +} + +class Baz{ + mixin Foo bar; +} + +int main() { + status = 3; + Baz b = new Baz(); + if(b.bar.func!()() != 3){ + assert(0); + } + + return 0; +} +
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/run/b/bug_e2ir_736_B.d Fri Jun 02 16:56:21 2006 +0000 @@ -0,0 +1,34 @@ +// $HeadURL$ +// $Date$ +// $Author$ + +// @author@ <h3r3tic@mat.uni.torun.pl> +// @date@ 2006-06-01 +// @uri@ news:bug-172-3@http.d.puremagic.com/bugzilla/ + +module dstress.run.b.bug_e2ir_736_B; + +int status; + +template Foo(){ + template funcT() { + int func() { + return status; + } + } +} + +class Baz{ + mixin Foo bar; +} + +int main() { + status = 3; + Baz b = new Baz(); + if(b.bar.funcT!().func() != 3){ + assert(0); + } + + return 0; +} +
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/run/b/bug_e2ir_736_C.d Fri Jun 02 16:56:21 2006 +0000 @@ -0,0 +1,32 @@ +// $HeadURL$ +// $Date$ +// $Author$ + +// @author@ <h3r3tic@mat.uni.torun.pl> +// @date@ 2006-06-01 +// @uri@ news:bug-172-3@http.d.puremagic.com/bugzilla/ + +module dstress.run.b.bug_e2ir_736_C; + +int status; + +template Foo(){ + int func() { + return status; + } +} + +class Baz{ + mixin Foo bar; +} + +int main() { + status = 3; + Baz b = new Baz(); + if(b.bar.func() != 3){ + assert(0); + } + + return 0; +} +
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/run/b/bug_e2ir_736_D.d Fri Jun 02 16:56:21 2006 +0000 @@ -0,0 +1,33 @@ +// $HeadURL$ +// $Date$ +// $Author$ + +// @author@ <h3r3tic@mat.uni.torun.pl> +// @date@ 2006-06-01 +// @uri@ news:bug-172-3@http.d.puremagic.com/bugzilla/ + +module dstress.run.b.bug_e2ir_736_D; + +int status; + +template Foo(){ + template T(){ + int func() { + return status; + } + } +} + +class Baz{ + mixin Foo bar; +} + +int main() { + status = 3; + if(Baz.bar.T!().func() != 3){ + assert(0); + } + + return 0; +} +