RFR: JDK-8283730: Improve discussion of modeling of packages and modules
Alex Buckley
alex.buckley at oracle.com
Tue Mar 29 16:18:51 UTC 2022
On 3/28/2022 6:30 PM, Joseph D. Darcy wrote:
> Okay; I added the "standalone" adjective to describe module-info file,
> paralleling the wording used to describe package-info and added
> "[implicit information] may be used" for for automatic modules:
>
> "The represented module may have an explicit backing construct (either
> source code or executable output) or may be created from implicit
> information. The explicit and standalone source code construct for a
> module is typically a module-info.java file (JLS 7.7). Implicit
> information is used to model unnamed modules and may be used for
> automatic modules (JLS 7.7.1)."
>
> (I think an explicit module-info.java file has a different degree of
> explicitness than an Automatic-Module-Name attribute, but don't think
> describing possibilities of Automatic-Module-Name attributes would be
> helpful in this context.)
As a reader, I can't tell if an automatic module is going to be exposed
as a ModuleElement, and if it is, where the name is going to originate.
In other words, saying that _implicit_ info _may_ be used to model a
first-class platform concept is too weak IMO.
Alex
More information about the compiler-dev
mailing list