Greetings!

I have a moderate-sized project (about 15 directories, 700 files, 130kLOC
of C++; tag file shows 900 compounds and 5k members).

I'm finding at least one function is not getting added to the
documentation, despite the fact that it is properly documented, and the
file itself is properly documented.  (The file, and an enumeration defined
in it, *are* properly added to the documentation).

It's a pattern I use in a few other places, and those other places work
fine.  Namely, I have a .hpp with a namespace and a documented function
declaration within that namespace; then I have a corresonding .cpp file
with the namespace and the undocumented function definition within that
namespace.  This works fine in other cases, but not in this case.

I reduce it to a single .cpp/.hpp pair, and replicate the problem, even
with a nearly-default configuration (only added input and output
directories).  If I remove the .cpp file, then the documentation is created
correctly.

I have the example files here:

http://foiani.home.dyndns.org/~tony/doxygen/disappearing-func/

I've also created a .tar.gz of the directory, which you can download at
this URL:

http://foiani.home.dyndns.org/~tony/doxygen/disappearing-func.tar.gz

This is with top-of-SVN doxygen, although I've replicated the problem with
1.8.1.1 (fedora doxygen-1.8.1.1-3.fc17.x86_64).

In particular, the function "parseDHMS" in src/ParseDHMS.hpp is not output
at all.

Everything else in that file is picked up (including some typedefs that I
added to make sure it wasn't a case of "last decl got silently dropped" nor
"using return type to be same as previous compound causes issues".

If I remove src/ParseDHMS.cpp, then it works correctly.

The debugging output isn't very enlightening, at least not to me; with -d
Functions -d FindMembers, I see:

Building member list...
FUNCTION_SEC:
  `ParseDHMSFormat' `UNAP'::`parseDHMS' `(const string dhms, int &day, int
&hour, int &minute, int &second)' relates=`(null)' relatesType=`0'
file=`/home/tony/FoianiLLC/unap/docs/try1/src/ParseDHMS.cpp' line=`58'
bodyLine=`53' #tArgLists=-1 mGrpId=-1 spec=0 proto=0 docFile=(null)
  --> new function parseDHMS found!
  Global Function:
    `ParseDHMSFormat' `UNAP'::`parseDHMS' `(const string dhms, int &day,
int &hour, int &minute, int &second)' proto=0
    def=`ParseDHMSFormat UNAP::parseDHMS'
FUNCTION_SEC:
  `ParseDHMSFormat' `UNAP'::`parseDHMS' `(const string dhms, int &day, int
&hour, int &minute, int &second)' relates=`(null)' relatesType=`0'
file=`/home/tony/FoianiLLC/unap/docs/try1/src/ParseDHMS.hpp' line=`71'
bodyLine=`-1' #tArgLists=-1 mGrpId=-1 spec=0 proto=1
docFile=/home/tony/FoianiLLC/unap/docs/try1/src/ParseDHMS.hpp
  --> function parseDHMS already found!

I was suspicious about this sequence at first, but then I compared it
against a situation (in my full project) where it works fine -- and the
FUNCTION_SEC output is nearly identical (body found in .cpp but docFile is
null, then prototype is found in .hpp with docFile set to the .hpp, but in
that case, that function is documented correctly.)

Then, when it goes to find members...

findMemberDocumentation(): root->type=`ParseDHMSFormat'
root->inside=`UNAP::' root->name=`parseDHMS' root->args=`(const string
dhms, int &day, int &hour, int &minute, int &second)' section=6000000
root->spec=0 root->mGrpId=-1
findMember(root=0x1d13c00,funcDecl=`ParseDHMSFormat UNAP::parseDHMS(const
string dhms, int &day, int &hour, int &minute, int
&second)',related=`(null)',overload=0,isFunc=1 mGrpId=-1 tArgList=(nil)
(#=0) spec=0 lang=200
findMember() Parse results:
  namespaceName=`UNAP'
  className=`(null)`
  funcType=`ParseDHMSFormat'
  funcSpec=`(null)'
  funcName=`parseDHMS'
  funcArgs=`(const string dhms, int &day, int &hour, int &minute, int
&second)'
  funcTempList=`(null)'
  funcDecl=`ParseDHMSFormat UNAP::parseDHMS'
  related=`(null)'
  exceptions=`(null)'
  isRelated=0
  isMemberOf=0
  isFriend=0
  isFunc=1

1. funcName=`parseDHMS'
2.
findGlobalMember(namespace=UNAP,name=parseDHMS,tempArg=(null),decl=ParseDHMSFormat
UNAP::parseDHMS)
3. Found function scope
4. Try to add member `parseDHMS' to scope `UNAP'
5. Match found

But if I look at the final output for the UNAP scope, this function is not
included.

I tried to go through the code, but got thoroughly lost very quickly.  :(

If anyone has ideas, I would love to hear them.  I can work around this one
particular problem (insert guards in the .cpp to ignore it if building
documentation), but without understanding *why* it is happening, I will
need to audit every single item in my codebase by hand -- and I'd really
like to avoid that.

Many thanks in advance.

Best regards,
Anthony Foiani
------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_d2d_feb
_______________________________________________
Doxygen-users mailing list
Doxygen-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/doxygen-users

Reply via email to