Commit Graph

2 Commits

Author SHA1 Message Date
Ilyas Selimov
6ac057e620 IDEA-270438 - initial highlighting for switch patterns
Includes dominance, fall-through rules, completeness doesn't work, new quick fixes doesn't exist

GitOrigin-RevId: dcdd00ee8204fac5d9d172f5e71281887645cccd
2021-06-23 10:21:25 +00:00
Nikita Eshkeev
e0970fca77 [java][resolve] IDEA-271676 Pattern matching for switch: fix resolve
Fix the resolve algorithm according to [JEP 406](https://openjdk.java.net/jeps/406). It includes:

- The correct resolution of variables in pattern matching guards in both if and switch
- Restricting the maximal scope of resolving by the PsiSwitchLabeledRuleStatement
- Various tests for resolving variable in pattern matching for switch

Signed-off-by: Nikita Eshkeev <nikita.eshkeev@jetbrains.com>

GitOrigin-RevId: 1efb10f50a458a382a71ffeaef5a0f540b4a8893
2021-06-19 21:31:03 +00:00