int foo() { scope(failure) return 22; throw new Exception("E"); } unittest { assert(foo() == 22); } Is this defined behavior? At least in x64 dmd the exception is swallowed and the assert evaluates to true. In any case what should happen? Should the method return or should the exception be propagated up the callstack?