RFR: JDK-8207160: ClassReader::adjustMethodParams can potentially return null if the args list is empty
Vicente Romero
vicente.romero at oracle.com
Wed Sep 12 20:50:31 UTC 2018
On 09/12/2018 04:41 PM, Maurizio Cimadamore wrote:
>
> There's no copyright on the jasm file - is that deliberate?
>
I just forgot :|, I have updated the webrev:
http://cr.openjdk.java.net/~vromero/8207160/webrev.02/jdk.dev.patch
<http://cr.openjdk.java.net/%7Evromero/8207160/webrev.00/jdk.dev.patch>
> Thanks
> Maurizio
>
>
> On 12/09/18 21:23, Liam Miller-Cushon wrote:
>> Looks good, thanks!
>>
>> On Wed, Sep 12, 2018 at 12:36 PM Vicente Romero
>> <vicente.romero at oracle.com <mailto:vicente.romero at oracle.com>> wrote:
>>
>> Hi Liam,
>>
>> Thanks for your comments, I have updated the patch [1],
>>
>> [1]
>> http://cr.openjdk.java.net/~vromero/8207160/webrev.01/jdk.dev.patch
>> <http://cr.openjdk.java.net/%7Evromero/8207160/webrev.00/jdk.dev.patch>
>>
>> On 09/10/2018 06:54 PM, Liam Miller-Cushon wrote:
>>> Hi Vicente,
>>>
>>> This looks good to me, for what that's worth.
>>>
>>> A couple of nits:
>>> * Consider doing the `args.isEmpty()` check earlier, at the
>>> beginning of adjustMethodParams or even before it's called. It
>>> might be slightly clearer, and it avoids processing the empty
>>> list and creating an unnecessary ListBuffer.
>>> * I thought more descriptive test names were now preferred over
>>> T8207160-style names?
>>>
>>> On Mon, Sep 10, 2018 at 2:13 PM Vicente Romero
>>> <vicente.romero at oracle.com <mailto:vicente.romero at oracle.com>>
>>> wrote:
>>>
>>> ping
>>>
>>> On 08/31/2018 03:18 PM, Vicente Romero wrote:
>>> > Please review the fix for [1] at [2]. The bug was found by
>>> a user that
>>> > was compiling some classes with JDK11 while having some
>>> old libs built
>>> > with JDK6 in the class path. It seems like some versions
>>> of javac6
>>> > produced constructors for inner classes with no arguments.
>>> This is not
>>> > expected by newer versions of javac and it was producing a
>>> NPE. This
>>> > fix aims at making sure that
>>> ClassReader::adjustMethodParams wont
>>> > return a null even if the list of arguments passed to it
>>> is empty.
>>> >
>>> > TIA,
>>> > Vicente
>>> >
>>> > [1] https://bugs.openjdk.java.net/browse/JDK-8207160
>>> > [2]
>>> http://cr.openjdk.java.net/~vromero/8207160/webrev.00/jdk.dev.patch
>>> <http://cr.openjdk.java.net/%7Evromero/8207160/webrev.00/jdk.dev.patch>
>>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/compiler-dev/attachments/20180912/e5fca13d/attachment.html>
More information about the compiler-dev
mailing list