[Issue 9372] Class member with @disabled ctor makes class ctor unusable

d-bugmail at puremagic.com d-bugmail at puremagic.com
Tue Jan 22 23:34:25 PST 2013


http://d.puremagic.com/issues/show_bug.cgi?id=9372


Jacob Carlborg <doob at me.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |doob at me.com


--- Comment #1 from Jacob Carlborg <doob at me.com> 2013-01-22 23:34:19 PST ---
I don't know if this makes any sense but:

When the code "new Room" is run the runtime will first create a new instance of
"Room" and initialize all fields. It will then run the constructor. Technically
you don't need to run the constructor at all, I don't do that in my
serialization library. The field "t" cannot be initialized because it has its
default constructor disabled. I'm not sure if the default constructor of
Trouble is the same as "Trouble.init". If not, I think this should compile. If
it is the same, then this error perhaps makes sense.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list