Mercurial > projects > dstress
view run/InExpression_06.d @ 180:da000f026b76
1) added InExpression tests
2) added passed/failed explanations to the summary page
author | thomask |
---|---|
date | Tue, 07 Dec 2004 12:04:08 +0000 |
parents | |
children | 557e7af55dfc |
line wrap: on
line source
// $HeadURL$ // $Date$ // $Author$ module dstress.run.InExpression_06; struct MyStruct{ int i; char c; } int main(){ MyStruct value; value.i = 1; value.c = '1'; char[] key = "eins"; MyStruct[char[]] array; array[key]=value; MyStruct* ptr = key in array; assert(value.i == ptr.i); assert(value.c == ptr.c); value.i++; value.c--; assert(value.i == ptr.i); assert(value.c == ptr.c); return 0; }