May 03 [Issue 24535] New: Accepts Invalid: goto can skip declarations if they're labelled | ||||
---|---|---|---|---|
| ||||
https://issues.dlang.org/show_bug.cgi?id=24535 Issue ID: 24535 Summary: Accepts Invalid: goto can skip declarations if they're labelled Product: D Version: D2 Hardware: x86 OS: Mac OS X Status: NEW Severity: normal Priority: P1 Component: dmd Assignee: nobody@puremagic.com Reporter: ben.james.jones@gmail.com void f1(){ //fails with error about skipping a declaration int x; goto Label; int y; Label: int z; } void f2(){ //compiles fine int x; goto Label; Dummy: int y; Label: int z; } -- |
Copyright © 1999-2021 by the D Language Foundation