Hello,

Please review the patch below which addresses

    JDK-8020810: Typo in javadoc for Class.toGenericString()

A note of explanation for the change in j.l.Class, the essence of the change is replacing

    {@code @interface}

with

    <code>&#64;</code>{@code interface}

The construct "{@code &#64;interface}" doesn't render right; the literal text "&#64;" is output rather than "@". However, "@" is problematic inside {@oode } since it gets confused as a javadoc tag. Likewise, "<code>@</code>" doesn't work for the same reason. In the end, "<code>&#64;</code>{@code interface}" gives the desired output of "@interface".

As a bonus, a javadoc issue in j.l.r.Parameter is fixed too.

Thanks,

-Joe

--- a/src/share/classes/java/lang/Class.java Wed Jul 17 00:34:39 2013 -0700 +++ b/src/share/classes/java/lang/Class.java Thu Jul 18 22:48:04 2013 -0700
@@ -157,10 +157,10 @@
      *
      * The string is formatted as a list of type modifiers, if any,
      * followed by the kind of type (empty string for primitive types
-     * and {@code class}, {@code enum}, {@code interface}, or {@code
-     * &#64;interface}, as appropriate), followed by the type's name,
-     * followed by an angle-bracketed comma-separated list of the
-     * type's type parameters, if any.
+     * and {@code class}, {@code enum}, {@code interface}, or
+     * <code>&#64;</code>{@code interface}, as appropriate), followed
+     * by the type's name, followed by an angle-bracketed
+     * comma-separated list of the type's type parameters, if any.
      *
      * A space is used to separate modifiers from one another and to
      * separate any modifiers from the kind of type. The modifiers
diff -r cbdd2529d93a src/share/classes/java/lang/reflect/Parameter.java
--- a/src/share/classes/java/lang/reflect/Parameter.java Wed Jul 17 00:34:39 2013 -0700 +++ b/src/share/classes/java/lang/reflect/Parameter.java Thu Jul 18 22:48:04 2013 -0700
@@ -162,7 +162,7 @@

     /**
      * Returns the name of the parameter.  If the parameter's name is
-     * {@linkplain isNamePresent() present}, then this method returns
+     * {@linkplain #isNamePresent() present}, then this method returns
      * the name provided by the class file. Otherwise, this method
      * synthesizes a name of the form argN, where N is the index of
      * the parameter in the descriptor of the method which declares

Reply via email to