-
Bug
-
Resolution: Fixed
-
P3
-
12
There is a typo in the spec from section "16.1.8. switch Expression" (http://cr.openjdk.java.net/~gbierman/switch-expressions.html#jep325-16.1.8).
The following rule:
- V is definitely unassigned after a switch expression iff for every value break statement with expression e in the switch block that may exit the switch expression, V is definitely unassigned before the value breakstatement and V is *****definitely assigned***** after e.
It should read as:
- V is definitely unassigned after a switch expression iff for every value break statement with expression e in the switch block that may exit the switch expression, V is definitely unassigned before the value breakstatement and V is *****definitely unassigned***** after e.
As, if V is assigned after e, V will be assigned after switch expression.
The following rule:
- V is definitely unassigned after a switch expression iff for every value break statement with expression e in the switch block that may exit the switch expression, V is definitely unassigned before the value breakstatement and V is *****definitely assigned***** after e.
It should read as:
- V is definitely unassigned after a switch expression iff for every value break statement with expression e in the switch block that may exit the switch expression, V is definitely unassigned before the value breakstatement and V is *****definitely unassigned***** after e.
As, if V is assigned after e, V will be assigned after switch expression.