RFR: JDK-8222035: Unused variable declaration causes inference error
Vicente Romero
vicente.romero at oracle.com
Tue Apr 9 21:24:21 UTC 2019
thanks,
Vicente
On 4/9/19 4:37 PM, Maurizio Cimadamore wrote:
> Looks good!
>
> Maurizio
>
> On 09/04/2019 18:17, Vicente Romero wrote:
>> Hi Maurizio,
>>
>> Thanks for your comments, please see the updated webrev at [1]
>>
>> Vicente
>>
>> [1] http://cr.openjdk.java.net/~vromero/8222035/webrev.01/
>>
>>
>>
>> On 4/9/19 12:56 PM, Maurizio Cimadamore wrote:
>>> Looks good - few comments:
>>>
>>> * there's an HashSet still used at line 404:
>>>
>>> Set<Type> deps = minMap.getOrDefault(t.qtype, new
>>> HashSet<>(Collections.singleton(t.qtype)));
>>>
>>> This should be fixed too.
>>>
>>> * In this statement:
>>>
>>> ((UndetVar)asUndetVar(eq)).setInst(inferenceContext.asInstType(t));
>>>
>>> It would be better to cache the instantiated type outside the loop
>>> since it doesn't change.
>>>
>>> Maurizio
>>>
>>>
>>> On 09/04/2019 17:51, Vicente Romero wrote:
>>>> Hi all,
>>>>
>>>> Please review fix for [1] at [2]. The issue is random and very hard
>>>> to reproduce with a regression test. Apart from the use of
>>>> non-ordering preserving data structures, the root cause was early
>>>> resolution of the inference context which was leading, in this
>>>> case, to inexact instantiation of some inference variables.
>>>>
>>>> Thanks,
>>>> Vicente
>>>>
>>>> [1] https://bugs.openjdk.java.net/browse/JDK-8222035
>>>> [2] http://cr.openjdk.java.net/~vromero/8222035/webrev.00/
>>
More information about the compiler-dev
mailing list