http://d.puremagic.com/issues/show_bug.cgi?id=5256
bearophile_h...@eml.cc changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution| |DUPLICATE --- Comment #1 from bearophile_h...@eml.cc 2011-07-30 11:03:08 PDT --- assert(a !is null); is wrong code. Bug 4773 is now fixed. Now you are allowed to write: import std.stdio, std.typecons; const class Foo { invariant() { writeln("*"); } } void main() { auto a = Rebindable!Foo(new Foo); a = new Foo; //assert(a); // calls Foo.invariant() //assert(cast(bool)a); // doesn't call Foo.invariant(); auto f = new Foo(); assert(f); // calls Foo.invariant() assert(cast(bool)f); // doesn't call Foo.invariant(); } So I consider this bug too fixed. *** This issue has been marked as a duplicate of issue 4773 *** -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------