-
Bug
-
Resolution: Fixed
-
P2
-
6
-
b61
-
generic
-
generic
When you have a Java inheritance hierarchy like this:
A->B->C
and A and B both provide javadoc for some method m, and C has no doc comment
for method m, it should inherit from B, not from A, as appears to happen.
Self-explanatory shell transcript follows:
(C.html should contain "m1-B", not "m1-A")
$ cat [ABC].java; javadoc [ABC].java && grep 'm[0-9]-' C.html
public interface A {
/**
* m1-A
*/
void m1();
}
public interface B extends A {
/**
* m1-B
*/
void m1();
}
public class C implements B {
public void m1() {}
}
Loading source file A.java...
Loading source file B.java...
Loading source file C.java...
Constructing Javadoc information...
Standard Doclet version 1.6.0-ea
Building tree for all the packages and classes...
Generating A.html...
Generating B.html...
Generating C.html...
Generating package-frame.html...
Generating package-summary.html...
Generating package-tree.html...
Generating constant-values.html...
Building index for all the packages and classes...
Generating overview-tree.html...
Generating index-all.html...
Generating deprecated-list.html...
Building index for all classes...
Generating allclasses-frame.html...
Generating allclasses-noframe.html...
Generating index.html...
Generating help-doc.html...
Generating stylesheet.css...
m1-A</TD>
<DD>m1-A
###@###.### 2005-05-15 23:50:20 GMT
I am currently testing a fix for this. There is a bug where the list of superinterfaces or superclasses are sorted in alphabetical order. This is why we get the wrong inherited comments in some cases.
A->B->C
and A and B both provide javadoc for some method m, and C has no doc comment
for method m, it should inherit from B, not from A, as appears to happen.
Self-explanatory shell transcript follows:
(C.html should contain "m1-B", not "m1-A")
$ cat [ABC].java; javadoc [ABC].java && grep 'm[0-9]-' C.html
public interface A {
/**
* m1-A
*/
void m1();
}
public interface B extends A {
/**
* m1-B
*/
void m1();
}
public class C implements B {
public void m1() {}
}
Loading source file A.java...
Loading source file B.java...
Loading source file C.java...
Constructing Javadoc information...
Standard Doclet version 1.6.0-ea
Building tree for all the packages and classes...
Generating A.html...
Generating B.html...
Generating C.html...
Generating package-frame.html...
Generating package-summary.html...
Generating package-tree.html...
Generating constant-values.html...
Building index for all the packages and classes...
Generating overview-tree.html...
Generating index-all.html...
Generating deprecated-list.html...
Building index for all classes...
Generating allclasses-frame.html...
Generating allclasses-noframe.html...
Generating index.html...
Generating help-doc.html...
Generating stylesheet.css...
m1-A</TD>
<DD>m1-A
###@###.### 2005-05-15 23:50:20 GMT
I am currently testing a fix for this. There is a bug where the list of superinterfaces or superclasses are sorted in alphabetical order. This is why we get the wrong inherited comments in some cases.