RFR: 8357185: Redundant local variables with unconditionally matching primitive patterns [v2]

Chen Liang liach at openjdk.org
Tue Jul 8 14:17:40 UTC 2025


On Fri, 4 Jul 2025 17:40:02 GMT, Jan Lahoda <jlahoda at openjdk.org> wrote:

>> Both styles are adopted as we can observe in `jdk/test/langtools/tools/javac`. 
>> 
>> In any case the current name is definitely not descriptive as it has nothing to do with unconditionally exact testing inherently. This is done in `test/jdk/java/lang/runtime/ExactnessConversionsSupportTest.java` or other tests. Unconditionally exact conversion is the context but not the observed effect. 
>> 
>> The test name can be either `T8357185` or something descriptive like `RedundantVariablesInPrimitivePatterns`.
>
> The `T<number>` format is mostly frowned upon, and we mostly try to not use the convention for new tests. If we can have a good name, that's better.

I have readjusted this to be a classfile-focused test for primitive patterns and renamed accordingly.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/26107#discussion_r2192653788


More information about the compiler-dev mailing list