Struct default constructor - need some kind of solution for C++ interop
Lodovico Giaretta via Digitalmars-d
digitalmars-d at puremagic.com
Tue Sep 6 07:27:49 PDT 2016
On Tuesday, 6 September 2016 at 14:10:43 UTC, Ethan Watson wrote:
> @disable this() will hide the static opCall and the compiler
> will throw an error.
Yes, I realized that. My bad.
As @disable this is not actually defining a ctor, it should not
be signaled as hiding the opCall. To me, this looks like an
oversight in the frontend that should be fixed.
> static opCall doesn't work for the SomeOtherClass example
> listed in OP.
That's because it doesn't initialize (with static opCall) the
fields of SomeOtherClass, right? I guess that could be solved
once and for all with some template magic of the binding system.
More information about the Digitalmars-d
mailing list