http://d.puremagic.com/issues/show_bug.cgi?id=4290
Kevin Bealer <kevinbea...@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |kevinbea...@gmail.com --- Comment #1 from Kevin Bealer <kevinbea...@gmail.com> 2010-09-15 21:26:18 PDT --- Just ran into this as well; also, note that the page here gives the wrong version of the signature; it omits the critical const, so anyone running into this problem will be misguided. http://www.digitalmars.com/d/2.0/operatoroverloading.html#compare Also... it looks like some of the standard code such as in std.bitarray does this without the "const", so I imagine the standard library is broken, though I haven't tested whether bitarray's sort properly. I agree with bearophile's recommendation -- there is no value in accepting a signature for "standard" interfaces like opCmp that will not work. One other detail: both of the opCmp signatures seem to work when "<" is used, but for some reason, not with .sort. ?? I'm testing with 2.048. Thanks, Kevin Bealer -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------