-
CSR
-
Resolution: Approved
-
P4
-
None
-
None
-
behavioral
-
minimal
-
Difference specification of the same semantics.
-
Java API
-
SE
Summary
Change one overload of java.lang.reflect.Array.newInstance
to have an @implSpec
of calling the other method.
Problem
Pre-@implSpec
use of the notion of @implSpec
.
Solution
Use @implSpec
.
Specification
diff --git a/src/java.base/share/classes/java/lang/reflect/Array.java b/src/java.base/share/classes/java/lang/reflect/Array.java
index 16f5477af25..61dca04fca5 100644
--- a/src/java.base/share/classes/java/lang/reflect/Array.java
+++ b/src/java.base/share/classes/java/lang/reflect/Array.java
@@ -49,13 +49,11 @@ class Array {
/**
* Creates a new array with the specified component type and
* length.
+ * @implSpec
* Invoking this method is equivalent to creating an array
* as follows:
* <blockquote>
- * <pre>
- * int[] x = {length};
- * Array.newInstance(componentType, x);
- * </pre>
+ * {@code Array.newInstance(componentType, new int[]{length});}
* </blockquote>
*
* <p>The number of dimensions of the new array must not
- csr of
-
JDK-8312203 Improve specification of Array.newInstance
-
- Resolved
-