Jacob Carlborg wrote:
The following code does not cause a compile error:

int foo ()
{
    try
        int i;
catch (Exception)
        throw new Exception("");
}

Wouldn't it be quite obvious for the compiler to see that there is no return statement in the above function and give a compile error? The same also happens with scope(failure).

Mac OS X 10.5.7 dmd 1.056.

It gives an error for me on Windows when compiled with -w. If it doesn't on Mac, that's definitely a bug.

Reply via email to