Community
Participate
Working Groups
Using I20080520-2000. While reviewing patch for bug 228648, I compiled some test cases got from initial bug 195374 and realized that inner type with partial qualification are still not warned when compliance is 1.3 or 1.4 although the javadoc tool complains about these references. Here's the test case I use: package test.bug; public class X { public static class Y { public static class Z { /** * The position in the new method signature depends on * the position in the array passed to * {@link X.Y#foo(Y.Z[])} * {@link test.bug.X.Y#foo(Y.Z[])} */ public int bar() { return 0; } } public void foo(Z[] params) { } } } JDT compiler does not complain about it whatever the compliance is. Javadoc tool complains on 1.3.1 and 1.4.2: X.java:12: warning - Tag @link: can't find foo(Y.Z[]) in test.bug.X.Y X.java:12: warning - Tag @link: can't find foo(Y.Z[]) in test.bug.X.Y X.java:12: warning - Tag @link: can't find foo(Y.Z[]) in test.bug.X.Y X.java:12: warning - Tag @link: can't find foo(Y.Z[]) in test.bug.X.Y X.java:12: warning - Tag @link: can't find foo(Y.Z[]) in test.bug.X.Y X.java:12: warning - Tag @link: can't find foo(Y.Z[]) in test.bug.X.Y X.java:12: warning - Tag @link: can't find foo(Y.Z[]) in test.bug.X.Y X.java:12: warning - Tag @link: can't find foo(Y.Z[]) in test.bug.X.Y X.java:12: warning - Tag @link: can't find foo(Y.Z[]) in test.bug.X.Y X.java:12: warning - Tag @link: can't find foo(Y.Z[]) in test.bug.X.Y 10 warnings
sounds like a duplicate of bug 221539 where partially qualified references within the same package / compilation unit are not warned (though the javadoc tool complains about unresolved references) (agreed: initial fix for bug 195374 only fixed the single type reference case)
(In reply to comment #1) in fact not a dup of bug 221539, which deals with type references. Here, we fail to warn partially qualified references in JavadocArgumentExpression. So, as per bug 195374, the same fix should be applied, both in: Javadoc#verifyTypeReference(...) --> bug 221539 (patch in bug 222188) JavadocArgumentExpression#internalResolveType(...) --> this bug Not a regression.
(In reply to comment #1) similar to bug 195374 (as related to inner types qualification) but not a real duplicate. Also not that the javadoc tool raises warnings (though fewer) at 1.5 or 1.6 level: X.java:12: warning - Tag @link: can't find foo(Y.Z[]) in test.bug.X.Y X.java:12: warning - Tag @link: can't find foo(Y.Z[]) in test.bug.X.Y We should modify the abstract accordingly.
Created attachment 101465 [details] [proposed patch + test case] on top v_866
Created attachment 112322 [details] Updated patch on top of v_912 Fix a little bit tuned to avoid unnecessary message send.
Released for 3.5M2
Verified for 3.5M2 using I20080914-2000