netbeans icon indicating copy to clipboard operation
netbeans copied to clipboard

Add @param tag to a Markdown javadoc adds a new javadoc

Open lahodaj opened this issue 4 months ago • 0 comments

Apache NetBeans version

Apache NetBeans latest daily build

What happened

As noted in: https://github.com/apache/netbeans/pull/7491#issuecomment-2391587885

    ///
    /// @param str
    ///
    public static void foo(String str, int i) {}

the hint will suggest to insert the doc for i in the old format, ignoring that the method has already a block in the new format.

result:

    ///
    /// @param str
    ///

    /**
     *
     * @param str
     * @param i
     */
    public static void foo(String str, int i) {}

Language / Project Type / NetBeans Component

Java

How to reproduce

    ///
    /// @param str
    ///
    public static void foo(String str, int i) {}

the hint will suggest to insert the doc for i in the old format, ignoring that the method has already a block in the new format.

result:

    ///
    /// @param str
    ///

    /**
     *
     * @param str
     * @param i
     */
    public static void foo(String str, int i) {}

Did this work correctly in an earlier version?

No / Don't know

Operating System

(Presumably) any

JDK

JDK 23

Apache NetBeans packaging

Own source build

Anything else

No response

Are you willing to submit a pull request?

Yes

lahodaj avatar Oct 03 '24 15:10 lahodaj