-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Description
Describe the bug
Processing Java code
class Test {
void a(@SuppressWarnings("unused") int arg) {}
}
results in the following xml snippet:
...
<memberdef kind="function" id="classTest_1afebca10a87ae805fe13cc3dcf1064683" prot="package" static="no" const="no" explicit="no" inline="yes" virt="non-virtual">
<type>void</type>
<definition>void Test.a</definition>
<argsstring>(@SuppressWarnings("unused") int arg)</argsstring>
<name>a</name>
<qualifiedname>Test.a</qualifiedname>
<param>
<type>@SuppressWarnings("unused") int</type>
<declname>arg</declname>
</param>
...
Note the remaining annotation @SuppressWarnings
. This is inconsistent with the usual behavior of Doxygen to strip annotations away. Further, it adds garbage to the param type.
Expected behavior
I expect that the resulting code snippet would be as follows:
...
<memberdef kind="function" id="classTest_1afebca10a87ae805fe13cc3dcf1064683" prot="package" static="no" const="no" explicit="no" inline="yes" virt="non-virtual">
<type>void</type>
<definition>void Test.a</definition>
<argsstring>(int arg)</argsstring>
<name>a</name>
<qualifiedname>Test.a</qualifiedname>
<param>
<type>int</type>
<declname>arg</declname>
</param>
...
To Reproduce
Find a Java file and doxygen config attached. The issue is demonstrated like mentioned above.
After running doxygen on the example, the files in the subfolder xml
contain the snippet shown above.
issue_arg_annotation.zip
Version
Tested with doxygen clone from 2022-02-12:
/blah/doxygen/build/bin/doxygen -v
1.9.4 (5e664a014e6fa3149bdc807e4a55399020a012da)
lsb_release -a
:
LSB Version: core-9.20160110ubuntu0.2-amd64:core-9.20160110ubuntu0.2-noarch:security-9.20160110ubuntu0.2-amd64:security-9.20160110ubuntu0.2-noarch
Distributor ID: LinuxMint
Description: Linux Mint 18 Sarah
Release: 18
Codename: sarah
(yes I know a system update is overdue...)
Additional context
TBH I did not check for duplicates. Please excuse if this is a known issue.