Disallowing break label (and continue label) inside an expression switch
john.r.rose at oracle.com
Fri Mar 23 19:53:09 UTC 2018
On Mar 23, 2018, at 12:41 PM, Brian Goetz <Brian.Goetz at Oracle.COM> wrote:
> I think so. Its not detecting the ambiguity, its that the possibility of mixing control flow kinds means the poor reader has to reason about all the possibilities, and not be sure what "break FOO" means in a switch statement.
A lighter fix, then, would be to require parentheses always.
An even lighter fix would be leave that kind of clarification to style guides.
More information about the amber-spec-observers