RFR [9] 8132468: docs: replace <tt> tags (obsolete in html5) for java.io, java.lang, java.math

Daniel Fuchs daniel.fuchs at oracle.com
Mon Aug 3 12:17:27 UTC 2015


On 03/08/15 11:31, Alexander Stepanov wrote:
> Hello,
>
> Could you please review the following fix:
> http://cr.openjdk.java.net/~avstepan/8132468/webrev.00/
> for
> https://bugs.openjdk.java.net/browse/JDK-8132468
>
> Just some cleanup for docs (replacing obsolete "<tt></tt>").
>
> Thanks,
> Alexander

Hi Alexander,

mostly looks good to me - with afew remarks though.

In some files, such as
src/java.base/share/classes/java/io/Console.java and
src/java.base/share/classes/java/lang/ClassLoader.java
(possibly others) - you're using formatting like:

+    * <code>{@link #readLine}</code>.

The <code></code> is not needed around {@link } - as that should be
the default formatting for {@link } (we use {@linkplain } when we
don't want the code formatting for @link).


src/java.base/share/classes/java/io/File.java

+     * <blockquote><code>
+     * new File(</code><i> f</i><code>.{@link
+     * #toURI() toURI}()).equals(</code><i> f</i><code>.{@link
+     * #getAbsoluteFile() getAbsoluteFile}())
+     * </code></blockquote>

Would that be easier to read as:

      * <blockquote>{@code new File(f.}{@link
      * #toURI() toURI()}{@code .equals(f.}{@link
      * #getAbsoluteFile() getAbsoluteFile()}{@code )}
      * </blockquote>

(not sure why the original text has hard spaces &nbsp - as
  we usually don't put any space after an open parenthesis)

Same remark for this a few lines below:

+     * <blockquote><code>
+     * new {@link #File(java.net.URI) File}(</code><i> f</i>{@code
+     * .toURI()).equals(}<i> f</i><code>.{@link #getAbsoluteFile() 
getAbsoluteFile}())
+     * </code></blockquote>

I mean - I don't particularly object but if the goal is to replace
<code></code> and <tt></tt> everywhere - then why not go the full
way down?

The other question is whether <pre></pre> would be a better fit than
<blockquote><code></code></blockquote>.


Otherwise looks good!

-- daniel



More information about the core-libs-dev mailing list