https://issues.dlang.org/show_bug.cgi?id=16201
Issue ID: 16201 Summary: When all paths inside a static if return/throw, the portion after static if should be as if "else" were used Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: enhancement Priority: P1 Component: dmd Assignee: nob...@puremagic.com Reporter: and...@erdani.com Consider: static if (condition) { ... code 1 ... return; } ... code 2 ... This should be treated by the compiler the same as: static if (condition) { ... code 1 ... return; } else { ... code 2 ... } Currently it gets quite annoying to have to nest multiple static ifs and elses. --