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


Don <clugd...@yahoo.com.au> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |patch


--- Comment #2 from Don <clugd...@yahoo.com.au> 2009-10-29 12:58:44 PDT ---
PATCH: declaration.c, line 1094.
            {
            /* Look for opCall
             * See bugzilla 2702 for more discussion
             */
            Type *ti = ei->exp->type->toBasetype();
------- ADD THIS CODE:            
            // Look for ctor
            if (sd->ctor && 
                /* Initializing with the same type is done differently
                 */
                !(ti->ty == Tstruct && t->toDsymbol(sc) == ti->toDsymbol(sc)))
{
               // Rewrite as e1.call(arguments)
                Expression * eCall = new DotIdExp(loc, e1, Id::ctor);
                ei->exp = new CallExp(loc, eCall, ei->exp);
            } 
            else
-----------
            // Don't cast away invariant or mutability in initializer
            if (search_function(sd, Id::call) &&

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

Reply via email to