doxygen icon indicating copy to clipboard operation
doxygen copied to clipboard

Parameter types names duplicated with Doxygen 1.15.0

Open swt2c opened this issue 4 months ago • 2 comments

Describe the bug In Doxygen 1.15.0, I'm seeing duplicated parameter type names in certain cases when building documentation for wxWidgets (C++). This seems to be happening when the parameter is a typedef to another class. In this case, wxObjectRefData is a typedef to wxRefCounter (from interface/wx/object.h):

typedef wxRefCounter wxObjectRefData;

Screenshots See that wxObjectRefData is duplicated in GetRefData and SetRefData: Image

To Reproduce Sorry the example isn't exactly minimal but you can see the problem in classwx_object.html. I'll try to make a more minimal example. example.zip

Expected behavior Type name shouldn't be duplicated.

Version 1.15.0 on Fedora 43.

swt2c avatar Dec 05 '25 00:12 swt2c

I've minimized the problem already to a smaller project and I see in the file classwx_object.html the construct:

<a class="el" href="object_8h.html#ab7149af7eced89712baaf20432d66e19">wxObjectRefData</a>
<a class="el" href="classwx_object_ref_data.html">wxObjectRefData</a> 

So a double link, with 2 different destinations.

Example: example_2.tar.gz

I will have to do a bisect and see where the root cause of the problems lies. (A small indication is maybe the description of a class just above the typedef).

albert-github avatar Dec 05 '25 09:12 albert-github

The bisection gave:

3fb8336b630e33ce766d97caca8e4e80341b2ede is the first bad commit

Commit: 3fb8336b630e33ce766d97caca8e4e80341b2ede [3fb8336]

Date: Monday, October 20, 2025 4:41:35 PM

issue #11799 Incorrect link for template argument

@doxygen any ideas?

albert-github avatar Dec 05 '25 10:12 albert-github

I have done some tests trying to find a workaround for this:

  1. no change:
    • replacing the typedef with the more modern using wxObjectRefData = wxRefCounter;
  2. valid workarounds (the duplicate link disappears):
    • renaming wxObjectRefData to wx_ObjectRefData
    • renaming both wxObjectRefData to wx_ObjectRefData and wxObject to wx_Object
    • changing the doxygen annotation from @class wxObjectRefData to @typedef wxObjectRefData

simevo avatar Dec 09 '25 07:12 simevo

Wrote a potential fix: https://github.com/doxygen/doxygen/pull/11896.

BTW thanks for doing the bisection, made this easy.

PeakKS avatar Dec 11 '25 01:12 PeakKS

  • Code has been integrated in master on GitHub (please don't close the issue as this will be done at the moment of an official release).

albert-github avatar Dec 12 '25 08:12 albert-github