JDK 14 RFR of JDK-8230723: Remove default constructors from java.lang and java.io

Brian Burkhalter brian.burkhalter at oracle.com
Fri Sep 6 20:14:15 UTC 2019


Hi Joe,

> On Sep 6, 2019, at 11:12 AM, Joe Darcy <joe.darcy at oracle.com> wrote:
> 
> First part of a multi-part cleanup effort please review
> 
>     JDK-8230723: Remove default constructors from java.lang and java.io <http://java.io/>
>     webrev: http://cr.openjdk.java.net/~darcy/8230723.0/ <http://cr.openjdk.java.net/~darcy/8230723.0/>
>     CSR: https://bugs.openjdk.java.net/browse/JDK-8230724 <https://bugs.openjdk.java.net/browse/JDK-8230724>

CSR reviewed.

> Patch below.
> 
> The default constructors on Modifier and ConstantBootstraps seem clearly accidental so I deprecated them for removal.
> 
> The PrimitiveSlot and Factory classes are public classes within non-public classes so I made the constructors package private rather than public. However, this is not a spec change for the Java SE API.

On Factory I think the doc might be better as “Contructs” instead of “Construct” (like for ThreadDeath).

> I'll update the any copyright years as appropriate before pushing.

+1

Brian


More information about the core-libs-dev mailing list