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


clugd...@yahoo.com.au changed:

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




------- Comment #3 from clugd...@yahoo.com.au  2009-04-02 15:42 -------

in expression.c, in CallExp::canThrow(), around line 6660, type will be null if
the expression was invalid. Adding a null check fixes the segfault.

    /* If calling a function or delegate that is typed as nothrow,
     * then this expression cannot throw.
     * Note that pure functions can throw.
     */
        if (!e1->type) return 0;  // ---- add this line

    Type *t = e1->type->toBasetype();
    if (t->ty == Tfunction && ((TypeFunction *)t)->isnothrow)
        return 0;


-- 

Reply via email to