Summary
Remove terminally deprecated constructors in java.lang.reflect.Modifier
and java.lang.invoke.ConstantBootstraps
.
Problem
The constructors that were previously marked as deprecated are in need of removal.
Solution
Remove the constructors in question. Note as raised in the core-libs review thread, at least one non-public constructor needs to be added to preserve the effect of removing these public constructors. The implementation will use no-arg private constructors.
Specification
--- a/src/java.base/share/classes/java/lang/invoke/ConstantBootstraps.java Sat Dec 07 09:40:28 2019 +0800
+++ b/src/java.base/share/classes/java/lang/invoke/ConstantBootstraps.java Sun Dec 08 10:49:48 2019 -0800
@@ -40,12 +40,6 @@
* @since 11
*/
public final class ConstantBootstraps {
- /**
- * Do not call.
- */
- @Deprecated(forRemoval=true, since="14")
- public ConstantBootstraps() {}
-
// implements the upcall from the JVM, MethodHandleNatives.linkDynamicConstant:
/*non-public*/
static Object makeConstant(MethodHandle bootstrapMethod,
diff -r 31882abe1494 src/java.base/share/classes/java/lang/reflect/Modifier.java
--- a/src/java.base/share/classes/java/lang/reflect/Modifier.java Sat Dec 07 09:40:28 2019 +0800
+++ b/src/java.base/share/classes/java/lang/reflect/Modifier.java Sun Dec 08 10:49:48 2019 -0800
@@ -44,13 +44,6 @@
*/
public class Modifier {
/**
- * Do not call.
- */
- @Deprecated(forRemoval=true, since="14")
- public Modifier() {}
-
-
- /**
* Return {@code true} if the integer argument includes the
* {@code public} modifier, {@code false} otherwise.
*
- csr of
-
JDK-8230771 Remove terminally deprecated constructors in java.base
- Resolved