Menu

#1547 [java] UnusedImportRule - False Positive for only usage in Javadoc - {@link ClassName#CONSTANT}

PMD-5.4.4
closed
None
PMD
3-Major
Bug
5.4.3
Imports
2016-12-07
2016-11-15
Felix Otto
No

The following import gets marked as unused while it is used in the JavaDoc comment.

import java.net.HttpURLConnection;

/**
 * {@link HttpURLConnection#HTTP_NOT_ACCEPTABLE}
 */
public interface Interface {
}

While playing around with some PMD versions wrapped by the related maven plug-in I have seen, that the issue does not occur with PMD 5.0.5 (maven pmd plug-in 3.1) while it does as of PMD 5.1.2 (maven pmd plug-in 3.2).

Discussion

  • Juan Sotuyo

    Juan Sotuyo - 2016-12-07
    • assigned_to: Maraxus
    • Milestone: New Tickets --> PMD-5.4.4
    • Affects version: 5.5.2 --> 5.4.3
     
  • Juan Sotuyo

    Juan Sotuyo - 2016-12-07
    • summary: UnusedCode - False Positive for only usage in Javadoc - {@link ClassName#CONSTANT} --> [java] UnusedCode - False Positive for only usage in Javadoc - {@link ClassName#CONSTANT}
     
  • Juan Sotuyo

    Juan Sotuyo - 2016-12-07
    • summary: [java] UnusedCode - False Positive for only usage in Javadoc - {@link ClassName#CONSTANT} --> [java] UnusedImportRule - False Positive for only usage in Javadoc - {@link ClassName#CONSTANT}
     
  • Juan Sotuyo

    Juan Sotuyo - 2016-12-07
    • status: open --> closed
     
  • Juan Sotuyo

    Juan Sotuyo - 2016-12-07

    This will be released in PMD 5.4.4, 5.5.3 and later

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.