Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4501977

wrong message when @param tag not used on method

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • 1.4.0
    • 1.4.0
    • tools
    • beta3
    • sparc
    • solaris_9
    • Verified

      For the following testcase
      ===========================
      jtools-sqe:/home/vr128054/vertest/work/crash 119 % more test3.java
      /**
       * @author Vijayan
       * @deprecated dummy
       * @return noreturn
       * @param noparam
       * @throws don't throw
       */

      public class test3
      {
      }

      The javadoc gives the following log message dump
      =================================================

      jtools-sqe:/home/vr128054/vertest/work/crash 123 % javadoc test3.java
      Loading source file test3.java...
      Constructing Javadoc information...
      Standard Doclet version 1.4 beta (04 Aug 2001)

      Building tree for all the packages and classes...
      Building index for all the packages and classes...
      Generating overview-tree.html...
      Generating index-all.html...
      test3.java:9: warning - noparam tag not on method.
      Generating deprecated-list.html...
      Building index for all classes...
      Generating allclasses-frame.html...
      Generating allclasses-noframe.html...
      Generating index.html...
      Generating packages.html...
      Generating test3.html...
      test3.java:9: warning - test3: "@throws don't throw" used with test3, but should only be used with a method.
      test3.java:9: warning - test3: "@return noreturn" used with test3, but should only be used with a method.
      test3.java:9: warning - test3: "@param noparam" used with test3, but should only be used with a method.
      Generating package-list...
      Generating help-doc.html...
      Generating stylesheet.css...
      4 warnings


      The javadoc tool emits two warnings for @param on non-method, but this issue is being tracked by another bug id.

      But the defective message here is,

      test3.java:9: warning - noparam tag not on method.

      noparam is not a tag, it is the text followed by @param tag. Needs a fix if this message is to be retained, else remove the message totally.

      The messages look to be reported by tool and doclet separately, hence repetition.

            jhosunw Jamie Ho (Inactive)
            rvijayansunw Ra Vijayan (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: