JDK-4618686 : REGRESSION: {@inheritDoc} does not work
  • Type: Bug
  • Component: tools
  • Sub-Component: javadoc(tool)
  • Affected Version: 1.3.0,1.4.0
  • Priority: P2
  • Status: Closed
  • Resolution: Fixed
  • OS: generic,solaris_2.6
  • CPU: generic,sparc
  • Submitted: 2002-01-02
  • Updated: 2020-08-31
  • Resolved: 2002-04-06
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
Other
1.4.1 hopperFixed
Related Reports
Duplicate :  
Description

Name: rmT116609			Date: 01/02/2002


FULL PRODUCT VERSION :
Java(TM) 2 Runtime Environment, Standard Edition (build
1.4.0-beta3-b84)
Java HotSpot(TM) Client VM (build 1.4.0-beta3-b84, mixed
mode)

FULL OPERATING SYSTEM VERSION :

Windows NT Version 4.0



A DESCRIPTION OF THE PROBLEM :
The {@inheritDoc} does not copy comments from superclasses
as it's supposed to do. It just puts '{@inheritDoc}' in the
output html file.


STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1. Create two files:

SuperClass.java:

/**
 * A SuperClass comment.
 */
public class SuperClass {
	/**
	 * The comment for the superclass method.
	 */
	public void method() {}
}

and SubClass.java:

/**
 * A SubClass comment.
 */
public class SubClass extends SuperClass {
	/**
	 * {@inheritDoc}
	 */
	public void method() {}
}

2. Call javadoc ('javadoc SuperClass.java SubClass.java')
with the two files


EXPECTED VERSUS ACTUAL BEHAVIOR :
Actual result for the html code for the method method() in
SubClass.html:

<A NAME="method()"><!-- --></A><H3>method</H3>
<PRE>public void <B>method</B>()</PRE>
<DL>
<DD>{@inheritDoc}
<P>
<DD><DL>
<DT><B>Overrides:</B><DD><CODE><A
HREF="SuperClass.html#method()">method</A></CODE> in class
<CODE><A HREF="SuperClass.html">SuperClass</A></CODE></DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>

Expected result for the html code for the method method()
in SubClass.html:

<A NAME="method()"><!-- --></A><H3>method</H3>
<PRE>public void <B>method</B>()</PRE>
<DL>
<DD>The comment for the superclass method.
<P>
<DD><DL>
<DT><B>Overrides:</B><DD><CODE><A
HREF="SuperClass.html#method()">method</A></CODE> in class
<CODE><A HREF="SuperClass.html">SuperClass</A></CODE></DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>


This bug can be reproduced always.
(Review ID: 137746) 
======================================================================

Comments
CONVERTED DATA BugTraq+ Release Management Values COMMIT TO FIX: hopper FIXED IN: hopper INTEGRATED IN: hopper VERIFIED IN: hopper-beta
14-06-2004

EVALUATION Notice this is a dupe of 4514538, in which Jamie said the following: The new tag {@includeDoc} was implemented and tested properly for Beta 3, but then was reimplemented as a taglet, which broke it. We thought we had tested this, but discovered after Beta 3 shipped that it was broken. Fixing this should require fixing only a few of lines of code. This has to be fixed at: com.sun.tools.doclets.standard.HtmlStandardWriter ====================== This bug has been fixed in the class mentioned above. A regression test has been added called TestTagInheritenceWrapper.sh ###@###.### 2002-03-29 Verified using TestTagInheritanceWrapper.sh ###@###.### 2002-04-25
29-03-2002

PUBLIC COMMENTS This bug has been fixed. {@inheritDoc} now works in method documentation. ###@###.### 2002-03-29
29-03-2002