# HG changeset patch # User thomask # Date 1099028868 0 # Node ID fecc79e23cd8f20e13943cd0172789a5a53ce87f # Parent 5aab0626a3e98fcb6980694d2b56881255d75c72 Ivan Senji / news://ckpj76r3m@digitaldaemon.com / nttp://digitalmars.com/digitalmars.D.bugs:2117 diff -r 5aab0626a3e9 -r fecc79e23cd8 nocompile/bug_20041016_A.d --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/nocompile/bug_20041016_A.d Fri Oct 29 05:47:48 2004 +0000 @@ -0,0 +1,27 @@ +// @author@ Ivan Senji +// @date@ 2004-10-16 +// @uri@ news://ckpj76$2r3m$1@digitaldaemon.com +// @url@ nttp://digitalmars.com/digitalmars.D.bugs:2117 + +module dstress.nocompile.bug_20041016_A; + +class Conversion(T,U){ + typedef char Small; + class Big{ + char[2] dummy; + } + static Small Test(U u); + static Big Test(...); + static T MakeT(); + enum { + exists = (Test(MakeT())).sizeof == (Small).sizeof + } +} + +void variadicDummy(...){ +} + +int main (){ + variadicDummy(Conversion!(double,int).exists); + return 0; +} diff -r 5aab0626a3e9 -r fecc79e23cd8 nocompile/bug_20041016_B.d --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/nocompile/bug_20041016_B.d Fri Oct 29 05:47:48 2004 +0000 @@ -0,0 +1,27 @@ +// @author@ Ivan Senji +// @date@ 2004-10-16 +// @uri@ news://ckpj76$2r3m$1@digitaldaemon.com +// @url@ nttp://digitalmars.com/digitalmars.D.bugs:2117 + +module dstress.nocompile.bug_20041016_B; + +int getch(){ + return 0; +} + +void writefln(...){ +} + +class Cout{ + Cout set(int x){ + return this; + } + alias set opShl; +} + +int main ( ){ + Cout cout = new Cout; + cout << 5 << 4; + writefln,getch; + return 0; +}