Why D is annoying =P

Mehrdad wfunction at hotmail.com
Wed Oct 24 12:17:09 PDT 2012


I couldn't find a better title, sorry.


But yeah, I've spent too many hours on hunting down problems like 
these...


Could someone explain what's going on? Thanks!

import std.stdio;
struct S { int[int] aa; }
void main()
{
	writeln(  [1: 2]  ==   [1: 2] );  // true
	writeln(S([1: 2]) == S([1: 2]));  // false
}

(I'm on Windows DMD v2.060.)


More information about the Digitalmars-d mailing list