JDK 9 RFR of JDK-8073952: Spec of j.l.r.Method.toString/toGenericString need to be clarified

elena votchennikova elena.votchennikova at oracle.com
Fri Feb 27 11:38:13 UTC 2015


Hello,

Looks good to me.

Thank you,
Elena

On 27.02.2015 5:28, joe darcy wrote:
> Hello,
>
> Please review the small changes to address
>
>     JDK-8073952: Spec of j.l.r.Method.toString/toGenericString need to 
> be clarified
>     http://cr.openjdk.java.net/~darcy/8073952.0/
>
> Full patch below.
>
> In essence, the patch adds references to the JLS sections which talk 
> about interfaces and default methods.
>
> Thanks,
>
> -Joe
>
> --- old/src/java.base/share/classes/java/lang/reflect/Constructor.java 
> 2015-02-26 17:14:49.955169685 -0800
> +++ new/src/java.base/share/classes/java/lang/reflect/Constructor.java 
> 2015-02-26 17:14:49.799091677 -0800
> @@ -296,7 +296,8 @@
>       * constructor has default (package) access.
>       *
>       * @return a string describing this {@code Constructor}
> -     * @jls 8.8.3. Constructor Modifiers
> +     * @jls 8.8.3 Constructor Modifiers
> +     * @jls 8.9.2 Enum Body Declarations
>       */
>      public String toString() {
>          return sharedToString(Modifier.constructorModifiers(),
> @@ -342,7 +343,8 @@
>       * include type parameters
>       *
>       * @since 1.5
> -     * @jls 8.8.3. Constructor Modifiers
> +     * @jls 8.8.3 Constructor Modifiers
> +     * @jls 8.9.2 Enum Body Declarations
>       */
>      @Override
>      public String toGenericString() {
> --- old/src/java.base/share/classes/java/lang/reflect/Method.java 
> 2015-02-26 17:14:50.403393705 -0800
> +++ new/src/java.base/share/classes/java/lang/reflect/Method.java 
> 2015-02-26 17:14:50.227305697 -0800
> @@ -356,6 +356,8 @@
>       * @return a string describing this {@code Method}
>       *
>       * @jls 8.4.3 Method Modifiers
> +     * @jls 9.4   Method Declarations
> +     * @jls 9.6.1 Annotation Type Elements
>       */
>      public String toString() {
>          return sharedToString(Modifier.methodModifiers(),
> @@ -409,6 +411,8 @@
>       * @since 1.5
>       *
>       * @jls 8.4.3 Method Modifiers
> +     * @jls 9.4   Method Declarations
> +     * @jls 9.6.1 Annotation Type Elements
>       */
>      @Override
>      public String toGenericString() {
>




More information about the core-libs-dev mailing list