genjavadoc icon indicating copy to clipboard operation
genjavadoc copied to clipboard

Links to Java static fields are not correctly translated.

Open jroper opened this issue 9 years ago • 0 comments

I'm not sure if this applies to a broader scope, eg to methods or non static fields, but if I have a Java class with a static field:

public class Foo {
  public static final int BAR = 10;
}

And then I reference it in some scaladocs:

/**
 * A reference to [[Foo.BAR]]
 */

genjavadoc will produce:

/**
 * A reference to {@link Foo.BAR}
 */

This is not the right way to reference fields, javadoc will subsequently fail. It should produce:

/**
 * A reference to {@link Foo#BAR}
 */

This can be worked around by using the following incorrect Scaladoc:

/**
 * A reference to [[Foo#BAR]]
 */

jroper avatar Aug 25 '16 04:08 jroper