After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 686956 - Doxygen confuses C++ private nested classes with same name in base and derived class
Doxygen confuses C++ private nested classes with same name in base and derive...
Status: RESOLVED FIXED
Product: doxygen
Classification: Other
Component: build
1.8.2
Other Windows
: Normal normal
: ---
Assigned To: Dimitri van Heesch
Dimitri van Heesch
Depends on:
Blocks:
 
 
Reported: 2012-10-26 20:15 UTC by Stephen McCracken
Modified: 2012-12-26 16:09 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Testcase with example incorrect collaboration diagram (8.20 KB, application/zip)
2012-10-26 20:21 UTC, Stephen McCracken
Details

Description Stephen McCracken 2012-10-26 20:15:04 UTC
If a C++ base class ClassA and a derived class ClassB both use the "private implementation" pattern and define a nested private class with the same name (say ClassA::Implementation and ClassB::Implementation), then ClassB's collaboration diagram and member data documentation incorrectly links to ClassA::Implementation rather than ClassB::Implementation.  Note, however, that the "Classes" section refers to the correct type.

The example below illustrates the issue.  I will attach a source file and a Doxygen config file that illustrate the problem.  You should only need to change the Doxygen working directory in order to run it.

Also reproducing the source file below for completeness:
--------------------------------------------------------
#include <boost::scoped_ptr.hpp>
#include <string>

/// This is a base class with a private implementation.
class ClassA 
{
public:
  ClassA();
private:
  class Implementation;
  boost::scoped_ptr< Implementation > mImpl;
};

/// This is a derived class with its own independent private implementation.
class ClassB : public ClassA
{
public:
  ClassB();
private:
  class Implementation;
  boost::scoped_ptr< Implementation > mImpl;
};

ClassA::ClassA() : mImpl() {}
ClassB::ClassB() : ClassA(), mImpl() {}

///  This is the private implementation for ClassA.
class ClassA::Implementation 
{
public:
  Implementation() {}
  std::string mData;
};

/// This is the private implementation for ClassB.
class ClassB::Implementation 
{
public:
  Implementation() {}
  std::string mData;
};
Comment 1 Stephen McCracken 2012-10-26 20:21:30 UTC
Created attachment 227386 [details]
Testcase with example incorrect collaboration diagram
Comment 2 Dimitri van Heesch 2012-10-27 21:54:08 UTC
Confirmed. Should be fixed in the next subversion update.
Comment 3 Dimitri van Heesch 2012-12-26 16:09:18 UTC
This bug was previously marked ASSIGNED, which means it should be fixed in
doxygen version 1.8.3. Please verify if this is indeed the case. Reopen the
bug if you think it is not fixed and please include any additional information
that you think can be relevant.