Issue ID: 18605
           Summary: False unreachable warning generated when labeled
                    continue is used
           Product: D
           Version: D2
          Hardware: x86_64
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P1
         Component: dmd

Code example:

auto test(T...)(int t) {
        L:foreach(_; T) {
                if (t)
                        continue L;
                return 1;
        new int; // <-- reported as unreachable

int _() {
        return test!(1,2,3)(1);

While in reality the reachability of 'new int' is dependent on parameter 't'.


Reply via email to