8191867: Module attribute in 54.0+ class file cannot contains a requires java.base with ACC_TRANSITIVE or ACC_STATIC_PHASE

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

8191867: Module attribute in 54.0+ class file cannot contains a requires java.base with ACC_TRANSITIVE or ACC_STATIC_PHASE

Alan Bateman
The draft JVMS for Java SE 10 forbids an entry in the requires table of
a Module attribute in a 54.0 or newer class file to require java.base
with the ACC_TRANSITIVE or ACC_STATIC_PHASE modifiers. This needs an
update to the module-info.class parser:
    http://cr.openjdk.java.net/~alanb/8191867/webrev/

For now, the ModuleDescriptor.Builder API is not updated but arguably it
should so that it retains its alignment with what is allowed and not
allowed in the Java Language.

-Alan


Reply | Threaded
Open this post in threaded view
|

Re: 8191867: Module attribute in 54.0+ class file cannot contains a requires java.base with ACC_TRANSITIVE or ACC_STATIC_PHASE

Paul Sandoz


> On 6 Dec 2017, at 07:42, Alan Bateman <[hidden email]> wrote:
>
> The draft JVMS for Java SE 10 forbids an entry in the requires table of a Module attribute in a 54.0 or newer class file to require java.base with the ACC_TRANSITIVE or ACC_STATIC_PHASE modifiers. This needs an update to the module-info.class parser:
>    http://cr.openjdk.java.net/~alanb/8191867/webrev/
>

66 private int JAVA_MIN_SUPPORTED_VERSION = 53;
67 private int JAVA_MAX_SUPPORTED_VERSION = 54;

Make 'em final:


 403                         + "java.base includes ACC_TRANSITIVIE or ACC_STATIC_PHASE”);

s/ACC_TRANSITIVIE/ACC_TRANSITIVE

Paul.

> For now, the ModuleDescriptor.Builder API is not updated but arguably it should so that it retains its alignment with what is allowed and not allowed in the Java Language.
>
> -Alan
>
>

Reply | Threaded
Open this post in threaded view
|

Re: 8191867: Module attribute in 54.0+ class file cannot contains a requires java.base with ACC_TRANSITIVE or ACC_STATIC_PHASE

Jonathan Gibbons
In reply to this post by Alan Bateman
There should probably be an equivalent javac update.

-- Jon


On 12/6/17 7:42 AM, Alan Bateman wrote:

> The draft JVMS for Java SE 10 forbids an entry in the requires table
> of a Module attribute in a 54.0 or newer class file to require
> java.base with the ACC_TRANSITIVE or ACC_STATIC_PHASE modifiers. This
> needs an update to the module-info.class parser:
>    http://cr.openjdk.java.net/~alanb/8191867/webrev/
>
> For now, the ModuleDescriptor.Builder API is not updated but arguably
> it should so that it retains its alignment with what is allowed and
> not allowed in the Java Language.
>
> -Alan
>
>

Reply | Threaded
Open this post in threaded view
|

Re: 8191867: Module attribute in 54.0+ class file cannot contains a requires java.base with ACC_TRANSITIVE or ACC_STATIC_PHASE

Alan Bateman
In reply to this post by Paul Sandoz


On 06/12/2017 17:00, Paul Sandoz wrote:

>
>> On 6 Dec 2017, at 07:42, Alan Bateman <[hidden email]> wrote:
>>
>> The draft JVMS for Java SE 10 forbids an entry in the requires table of a Module attribute in a 54.0 or newer class file to require java.base with the ACC_TRANSITIVE or ACC_STATIC_PHASE modifiers. This needs an update to the module-info.class parser:
>>     http://cr.openjdk.java.net/~alanb/8191867/webrev/
>>
> 66 private int JAVA_MIN_SUPPORTED_VERSION = 53;
> 67 private int JAVA_MAX_SUPPORTED_VERSION = 54;
>
> Make 'em final:
>
>
>   403                         + "java.base includes ACC_TRANSITIVIE or ACC_STATIC_PHASE”);
>
> s/ACC_TRANSITIVIE/ACC_TRANSITIVE
>
Thanks, I actually fixed both of these yesterday but didn't update the
webrev :-)

-Alan
Reply | Threaded
Open this post in threaded view
|

Re: 8191867: Module attribute in 54.0+ class file cannot contains a requires java.base with ACC_TRANSITIVE or ACC_STATIC_PHASE

Mandy Chung
In reply to this post by Paul Sandoz


On 12/6/17 9:00 AM, Paul Sandoz wrote:

>
>> On 6 Dec 2017, at 07:42, Alan Bateman <[hidden email]> wrote:
>>
>> The draft JVMS for Java SE 10 forbids an entry in the requires table of a Module attribute in a 54.0 or newer class file to require java.base with the ACC_TRANSITIVE or ACC_STATIC_PHASE modifiers. This needs an update to the module-info.class parser:
>>     http://cr.openjdk.java.net/~alanb/8191867/webrev/
>>
> 66 private int JAVA_MIN_SUPPORTED_VERSION = 53;
> 67 private int JAVA_MAX_SUPPORTED_VERSION = 54;
>
> Make 'em final:
>
>
>   403                         + "java.base includes ACC_TRANSITIVIE or ACC_STATIC_PHASE”);
>
> s/ACC_TRANSITIVIE/ACC_TRANSITIVE

or it can print "java.base includes " + mods?

otherwise, looks good.

Mandy
Reply | Threaded
Open this post in threaded view
|

Re: 8191867: Module attribute in 54.0+ class file cannot contains a requires java.base with ACC_TRANSITIVE or ACC_STATIC_PHASE

Alan Bateman

On 06/12/2017 17:17, mandy chung wrote:
>
> or it can print "java.base includes " + mods?
I've adjusted the exception text so that it reads:
    "The requires entry for java.base has ACC_TRANSITIVE set"

and updated the webrev in place. If you agree then I'll get this into
jdk/jdk10 to meet up with Paul's bump of the class file version to 54.0.

-Alan
Reply | Threaded
Open this post in threaded view
|

Re: 8191867: Module attribute in 54.0+ class file cannot contains a requires java.base with ACC_TRANSITIVE or ACC_STATIC_PHASE

Mandy Chung


On 12/7/17 6:56 AM, Alan Bateman wrote:
>
> On 06/12/2017 17:17, mandy chung wrote:
>>
>> or it can print "java.base includes " + mods?
> I've adjusted the exception text so that it reads:
>    "The requires entry for java.base has ACC_TRANSITIVE set"
>
> and updated the webrev in place. If you agree then I'll get this into
> jdk/jdk10 to meet up with Paul's bump of the class file version to 54.0.

+1

Mandy