RFR: 8367530: The exhaustiveness errors could be improved [v13]

Maurizio Cimadamore mcimadamore at openjdk.org
Wed Jan 28 08:57:28 UTC 2026


On Tue, 27 Jan 2026 16:39:15 GMT, Jan Lahoda <jlahoda at openjdk.org> wrote:

>> A possible suggestion might be to add this check inside `doExpandMissingPatternDescriptions` -- after the `if (toExpand instanceof BindingPattern bp) {` ?
>
> I've renamed the method. I also tried to put the check it on some other places; but unfortunately I couldn't find a better place where setting a sensible value (i.e. such that would not cancel tests in `ExhaustivenessConvenientErrors.java`, but would cancel `Exhaustiveness.testDeeplyNestedNotExhaustive`). 
> 
> Yes, during the "real" run, `baseChecks` should be `-`, and that should prevent the cancelation from happening.

For now let's keep the code as is, and see how this goes

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/27256#discussion_r2735528240


More information about the build-dev mailing list