Feedback on proposal for #ReflectiveAccessToNonExportedTypes

Jochen Theodorou blackdrag at gmx.org
Sat Jul 9 11:22:27 UTC 2016


On 09.07.2016 09:50, Alan Bateman wrote:
[...]
> As regards "enjoy special power" then the only module that is known to
> the VM and module system is "java.base". The java.base module, as you
> probably know, is the core of the system. The java.base modules has the
> VM, java.lang.**, the implementation of core reflection, method handles,
> and everything else that make up the core runtime and APIs. The other 70
> or so standard and JDK-specific modules [1] are just modules, no
> different to user modules that are deployed on the application module path.
>
> -Alan
>
> [1] http://openjdk.java.net/jeps/200

ok, let us assume I want to write a library that does what reflection 
can do today using bytecode generation. And let us assume I write a 
library, that will use this reflective module to call from private API 
to private API. How do we configure the two modules and what, besides 
the bytecode generation and the api, does the reflective library have to 
do (layers for example)? Would that have the same power as core 
reflection as far as the module system is concerned?

Since core reflection is in java.base, there is the assumption it enjoys 
special powers with regards to the module system. And that is especially 
because something like the layer system is still to unclear.

Oh... and let us assume there are two modules using this reflective 
module configured to be able to access their hidden API using the 
reflective library. Would this automatically allow the two libraries to 
call into the other hidden library?

bye Jochen




More information about the jigsaw-dev mailing list