RFR: 8305671: javac rejects semicolons in compilation units with no imports [v4]
Archie Cobbs
acobbs at openjdk.org
Wed May 24 14:37:00 UTC 2023
On Wed, 26 Apr 2023 02:58:23 GMT, Archie Cobbs <acobbs at openjdk.org> wrote:
>> The fix for [JDK-8027682](https://bugs.openjdk.org/browse/JDK-8027682) created a new bug in which a program like this:
>>
>> package p;;
>>
>> would be rejected.
>>
>> This is due to the previous fix swallowing all the semicolons. Instead, in the case of semicolons followed by EOF, it needs to swallow all but the last one.
>
> Archie Cobbs has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains five additional commits since the last revision:
>
> - Merge branch 'master' into JDK-8305671
> - Consume extra semicolons in a more straightforward way.
> - Merge branch 'master' into JDK-8305671
> - Use ToolBox and add more tests per review suggestion.
> - Allow a package declaration followed (only) by multiple commas.
pingbot
-------------
PR Comment: https://git.openjdk.org/jdk/pull/13361#issuecomment-1561279226
More information about the compiler-dev
mailing list