http://d.puremagic.com/issues/show_bug.cgi?id=10097
Igor Stepanov <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |[email protected] --- Comment #2 from Igor Stepanov <[email protected]> 2013-05-16 10:26:11 PDT --- (In reply to comment #1) > However, __postblit and __dtor are already used in Phobos - > hasElaborateCopyCoonstructor and hasElaborateDestructor. > > So, we should support additional __traits to replace the existing usage: > __traits(hasCtor, AggrType); > __traits(hasDtor, AggrType); > __traits(hasPostblit, AggrType); How I can get overloads of constructor? struct Foo { this(int){} this(int, Foo*){} } Now I can write: foreach(cur; __traits(getOverloads, Foo, "__ctor")) { //do something } If we'll drop "__ctor" access, we can get any alternative variant to get constructor overloads. May be access to constructor in C++ style is a better way? void delegate(int) ctor = &Foo.this; //this looks like function member in dot expression. void delegate() dtor = &Foo.~this; -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
