[ https://issues.apache.org/jira/browse/GROOVY-9546?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Paul King resolved GROOVY-9546. ------------------------------- Resolution: Fixed Merged. Thanks for spotting the issue and thanks to [~vmj] for the PR. > Annotations on class signature are rendered incorrectly > ------------------------------------------------------- > > Key: GROOVY-9546 > URL: https://issues.apache.org/jira/browse/GROOVY-9546 > Project: Groovy > Issue Type: Bug > Components: GroovyDoc > Affects Versions: 3.0.3 > Reporter: Damir Murat > Assignee: Paul King > Priority: Minor > Attachments: image-2020-05-10-17-42-34-810.png, > image-2020-05-10-17-47-00-858.png > > Time Spent: 1h 10m > Remaining Estimate: 0h > > When I have an annotated class, generated groovydoc contains a link to the > annotation and appended annotation name just after it as in following > screenshot: > !image-2020-05-10-17-47-00-858.png! > After some debugging, I managed to fix the issue by modifying > {code:java} > org/codehaus/groovy/tools/groovydoc/gstringTemplates/classLevel/classDocName.html.annotations(){code} > like this: > {noformat} > def annotations = { t, sepChar -> > // t.annotations() ? t.annotations().collect{ it.isTypeAvailable() ? '@' > + linkable(it.type().typeName()) + (it.description() - > ('@'+it.type().typeName())) : it.description()}.join(sepChar) + sepChar : '' > t.annotations() ? t.annotations().collect{ it.isTypeAvailable() ? '@' + > linkable(it.type().typeName()) : it.description()}.join(sepChar) + sepChar : > '' > } > {noformat} > -- This message was sent by Atlassian Jira (v8.3.4#803005)