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


Marco Leise <marco.le...@gmx.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |marco.le...@gmx.de


--- Comment #5 from Marco Leise <marco.le...@gmx.de> 2013-02-15 06:17:42 PST ---
(In reply to comment #4)
> The fact that it's **impossible** to call the constructor directly without an
> assignment getting in the way (as far as I see) is a bug.

I agree with you. I have a struct that is not supposed to be copied. Now I
cannot use it as a field in any other struct/class.

In some cases a work-around may be to allow assignments, but check that the
receiver is S.init.

Also I tried "= void" first. So it may be the most intuitive to use for the bug
fix.

I haven't checked, but it could allow code like this if not currently possible:

S s = void;
if (xyz) {
  s = S(3);
} else {
  s = S(7);
}

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

Reply via email to