# HG changeset patch # User thomask # Date 1171447745 0 # Node ID b34b5b54b00a0d45514a40f7b345d98929404edc # Parent 4595aefb732b8647747652b611a41b288d9c64e6 [Issue 887] TypeInfo does not correctly override opCmp, toHash Frits van Bommel 2007-01-25 http://d.puremagic.com/issues/show_bug.cgi?id=887 diff -r 4595aefb732b -r b34b5b54b00a run/t/typeid_91_A.d --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/run/t/typeid_91_A.d Wed Feb 14 10:09:05 2007 +0000 @@ -0,0 +1,20 @@ +// $HeadURL$ +// $Date$ +// $Author$ + +// @author@ Frits van Bommel +// @date@ 2007-01-25 +// @uri@ http://d.puremagic.com/issues/show_bug.cgi?id=887 +// @desc@ [Issue 887] TypeInfo does not correctly override opCmp, toHash + +module dstress.run.t.typeid_91_A; + +typedef int A; +typedef int B; + +int main(){ + if(0 == typeid(A).opCmp(typeid(B))){ + assert(0); + } + return 0; +} diff -r 4595aefb732b -r b34b5b54b00a run/t/typeid_91_B.d --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/run/t/typeid_91_B.d Wed Feb 14 10:09:05 2007 +0000 @@ -0,0 +1,20 @@ +// $HeadURL$ +// $Date$ +// $Author$ + +// @author@ Frits van Bommel +// @date@ 2007-01-25 +// @uri@ http://d.puremagic.com/issues/show_bug.cgi?id=887 +// @desc@ [Issue 887] TypeInfo does not correctly override opCmp, toHash + +module dstress.run.t.typeid_91_B; + +typedef int A; +alias A B; + +int main(){ + if(0 != typeid(A).opCmp(typeid(B))){ + assert(0); + } + return 0; +} diff -r 4595aefb732b -r b34b5b54b00a run/t/typeid_91_C.d --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/run/t/typeid_91_C.d Wed Feb 14 10:09:05 2007 +0000 @@ -0,0 +1,23 @@ +// $HeadURL$ +// $Date$ +// $Author$ + +// @author@ Frits van Bommel +// @date@ 2007-01-25 +// @uri@ http://d.puremagic.com/issues/show_bug.cgi?id=887 +// @desc@ [Issue 887] TypeInfo does not correctly override opCmp, toHash + +module dstress.run.t.typeid_91_C; + +class A{ +} + +class B{ +} + +int main(){ + if(0 == typeid(A).opCmp(typeid(B))){ + assert(0); + } + return 0; +} diff -r 4595aefb732b -r b34b5b54b00a run/t/typeid_91_D.d --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/run/t/typeid_91_D.d Wed Feb 14 10:09:05 2007 +0000 @@ -0,0 +1,23 @@ +// $HeadURL$ +// $Date$ +// $Author$ + +// @author@ Frits van Bommel +// @date@ 2007-01-25 +// @uri@ http://d.puremagic.com/issues/show_bug.cgi?id=887 +// @desc@ [Issue 887] TypeInfo does not correctly override opCmp, toHash + +module dstress.run.t.typeid_91_D; + +struct A{ +} + +struct B{ +} + +int main(){ + if(0 == typeid(A).opCmp(typeid(B))){ + assert(0); + } + return 0; +} diff -r 4595aefb732b -r b34b5b54b00a run/t/typeid_91_E.d --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/run/t/typeid_91_E.d Wed Feb 14 10:09:05 2007 +0000 @@ -0,0 +1,25 @@ +// $HeadURL$ +// $Date$ +// $Author$ + +// @author@ Frits van Bommel +// @date@ 2007-01-25 +// @uri@ http://d.puremagic.com/issues/show_bug.cgi?id=887 +// @desc@ [Issue 887] TypeInfo does not correctly override opCmp, toHash + +module dstress.run.t.typeid_91_E; + +enum A{ + X +} + +enum B{ + X +} + +int main(){ + if(0 == typeid(A).opCmp(typeid(B))){ + assert(0); + } + return 0; +} diff -r 4595aefb732b -r b34b5b54b00a run/t/typeid_91_F.d --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/run/t/typeid_91_F.d Wed Feb 14 10:09:05 2007 +0000 @@ -0,0 +1,25 @@ +// $HeadURL$ +// $Date$ +// $Author$ + +// @author@ Frits van Bommel +// @date@ 2007-01-25 +// @uri@ http://d.puremagic.com/issues/show_bug.cgi?id=887 +// @desc@ [Issue 887] TypeInfo does not correctly override opCmp, toHash + +module dstress.run.t.typeid_91_F; + +union A{ + int x; +} + +union B{ + int x; +} + +int main(){ + if(0 == typeid(A).opCmp(typeid(B))){ + assert(0); + } + return 0; +}