Skip to content

I20241126-0420

@srikanth-sankaran srikanth-sankaran tagged this 26 Nov 08:49
* Reimplement resolution, analysis and bookkeeping involved with `CaseStatement` and resolution of `SwitchStatement` for a streamlined and cleaner implementation resulting in readily obvious control flow and minimization of state.
* Report non-constant label expressions during resolution rather than waiting for flow analysis phase.
* Change how duplicate label expressions are reported. Don't blame the whole case, just the duplicate expression; Don't blame the original, just the duplicate.
* Represent qualified enumerators with qualified names internally so to avoid name clashes
* Eliminate the hack to inject synthetic `BreakStatement` in label rule switch blocks. Enhance the code generator to handle these explicitly.
* Simplify the implementation of SwitchStatement.getFallThroughState correcting various issues.
* Eliminate the unnecessary vector `SwitchStatement.constMapping` that is passed to `org.eclipse.jdt.internal.compiler.codegen.CodeStream.tableswitch` - constanMapping[i] == i always!
* Enable various tests in `PrimitiveInPatternsTest.java` that were disabled, fixing broken tests; Remove their disabled cousins from `PrimitiveInPatternsTestSH.java`
* Add a disabled regression test for #3319 (not yet understood/fixed)
* Numerous defect fixes as listed below

* Fixes https://github.com/eclipse-jdt/eclipse.jdt.core/issues/3336
* Fixes https://github.com/eclipse-jdt/eclipse.jdt.core/issues/3318
* Fixes https://github.com/eclipse-jdt/eclipse.jdt.core/issues/3320
* Fixes https://github.com/eclipse-jdt/eclipse.jdt.core/issues/3321
* Fixes https://github.com/eclipse-jdt/eclipse.jdt.core/issues/3334
* Fixes https://github.com/eclipse-jdt/eclipse.jdt.core/issues/3335
* Fixes https://github.com/eclipse-jdt/eclipse.jdt.core/issues/3265
* Fixes https://github.com/eclipse-jdt/eclipse.jdt.core/issues/3169
* Fixes https://github.com/eclipse-jdt/eclipse.jdt.core/issues/3339
* Fixes https://github.com/eclipse-jdt/eclipse.jdt.core/issues/3337
* Fixes https://github.com/eclipse-jdt/eclipse.jdt.core/issues/3344
Assets 2
Loading