GNOME Bugzilla – Bug 593040
Distributed member group documentation not properly distributed
Last modified: 2009-12-31 04:33:11 UTC
Created attachment 141663 [details] Class demonstrating the problem. When using DISTRIBUTE_GROUP_DOC and multiple groups, subsequent groups use the first groups documentation for all but the first member of the group. In the attached class func{1,2,3,5} are documented properly, but func4 and func6 have the documentation from the first group applied to them.
Created attachment 141664 [details] The Doxyfile for the test.
*** Bug 604412 has been marked as a duplicate of this bug. ***
I have been looking into this issue, and reported the duplicate bug (missed this one). I have been examining the behavior of the groups and how they are used. In your example there appears to be just one big group (as in mine). One of the main functions involved in distributing the documentation is MemberGroup::distributeMemberGroupDocumentation(), I came up with a patch that could likely be used by VTK which uses the member names, but this does not work in the general case. It looks like something in the logic of addMembersToMemberGroup() would need patching to create distinct groups for each group in a file, rather than what appears to happen now - one big group for each member of a group in a file.
The problem turned out to be in function findExistingGroup(). This function should compute a group id. For a previously defined member group it should return that group id or a new group id for a newly defined group. Anonymous groups (without name) should always get a fresh group id (now they all got the same group id). Patch is to replace in commentscan.l in function findExistingGroup(): if (g_compoundName==mi->compoundName && // same file or scope stricmp(mi->header,info->header)==0 // same header ) by if (g_compoundName==mi->compoundName && // same file or scope !mi->header.isEmpty() && // not nameless group and stricmp(mi->header,info->header)==0 // same header name ) Will be fixed in the next subversion update.
That is great news, I will patch our doxygen and test out your patch. I was hoping we could avoid staying with an old version for too long, but had not found any more time to look into the issue myself. Thanks for digging into the issue and providing a patch - our API docs thank you!
This bug was previously marked ASSIGNED, which means it should be fixed in doxygen version 1.6.2. Please verify if this is indeed the case and reopen the bug if you think it is not fixed (include any additional information that you think can be relevant).
We have started running the latest SVN snapshot of Doxygen on the VTK headers and things are now much improved. Thanks for looking into this and providing a patch in such a timely manner. Once 1.6.2 is released we will hopefully be able to move back to a released version. Thanks.