On Mon, 26 Jan 2026 12:21:49 GMT, Maurizio Cimadamore <[email protected]> 
wrote:

>> Also, `isBpCovered` seems to be called by routines (like 
>> `reduceRecordPattern`) that do not seem related to the new logic (which is 
>> what got me suspicious about the location of the update to begin with). 
>> Which has (at least in theory) potential for `TooManyChecksException` to 
>> trigger in places where it's not expected? (but maybe that's handled by the 
>> special value `-1` which is carefully set after the new logic runs)
>
> 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.

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

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

Reply via email to