Thread: Doxygen failing

  1. #1
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654

    Doxygen failing

    I just tried out Doxygen, but I'm running into trouble, because it doesn't seem to parse the code correctly for some reason.
    I get an error:
    Searching for include files...
    Searching for example files...
    Searching for images...
    Searching for dot files...
    Searching for files to exclude
    Searching for files to process...
    Searching for files in directory ...
    Reading and parsing tag files
    Building group list...
    Building directory list...
    Building namespace list...
    Building file list...
    Searching for included using directives...
    Building class list...
    Associating documentation with classes...
    Computing nesting relations for classes...
    Searching for members imported via using declarations...
    Building example list...
    Searching for enumerations...
    Searching for documented variables...
    Building member list...
    Searching for friends...
    Searching for documented defines...
    Computing class inheritance relations...
    Computing class usage relations...
    Flushing cached template relations that have become invalid...
    Creating members for template instances...
    Computing class relations...
    Searching for member function documentation...
    G:/w00t/Visual Studio 2005/Projects/Stuff/MemoryManager/BaseImpl.h:116: Warning: no uniquely matching class member found for
    template < T >
    void CMemoryManagerBase::Init()

    Building page list...
    Search for main page...
    Computing page relations...
    Determining the scope of groups...
    Sorting lists...
    Freeing entry tree
    Determining which enums are documented
    Computing member relations...
    Building full member lists recursively...
    Adding members to member groups.
    Computing member references...
    Inheriting documentation...
    Generating disk names...
    Adding source references...
    Adding todo/test/bug list items...
    Counting data structures...
    Resolving user defined references...
    Finding anchors and sections in the documentation...
    Combining using relations...
    Generating style sheet...
    Generating index page...
    Generating page index...
    Generating example documentation...
    Generating file sources...
    Generating file documentation...
    Generating page documentation...
    Generating group documentation...
    Generating group index...
    Generating class documentation...
    Generating annotated compound index...
    Generating hierarchical class index...
    Generating member index...
    Generating graphical class hierarchy...
    Generating namespace index...
    Generating namespace member index...
    Generating graph info page...
    Generating file index...
    Generating example index...
    Generating file member index...
    bool CMemoryManagerBase::operator!=(const CMemoryManagerNull &)
    G:/w00t/Visual Studio 2005/Projects/Stuff/MemoryManager/BaseImpl.h:562: Warning: no uniquely matching class member found for

    Problems running dot: exit code=-1, command='dot', arguments='"graph_legend.dot" -Tpng -o "graph_legend.png"'
    *** Doxygen has finished
    And a lot more like them. I don't get why because the code compiles fine and the definition and implementation do match:

    Code:
    template<typename T> class CMemoryManagerBase abstract
    {
    	//...
    	void Init();
    	// ...
    };
    
    template<typename T> void CMemoryManagerBase<T>::Init()
    {
    	p = NULL;
    	m_pInfo = NULL;
    }
    At the end, no documentation is generated. I don't know if it's because the functions aren't actually documented in the source or if it's because of errors?
    I don't really want to litter the source with a lot of documentation for the functions. I want to keep it separate in a help file instead. I don't know if doxygen is right for this, though.
    Last edited by Elysia; 04-11-2008 at 06:19 AM.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  2. #2
    (?<!re)tired Mario F.'s Avatar
    Join Date
    May 2006
    Location
    Ireland
    Posts
    8,446
    Yeah. Doxygen will require you to comment your code. However that's not the reason why you are getting those errors. Doxygen will function just fine as an indexer without any kind of commenting. I do wonder though why you don't want your code commented. With certain care, smart IDE color coding choices, and well placed code folding, I've been able to fully document code in the past for Doxygen without it getting in the way.

    Anyway, the problem seems related to Graphviz' Dot tool. You probably don't have it installed and opted for generating graphical representations of your code structure and relationships. Quite nice that tool, I must add...

    Right. So,

    Check here for some general info http://www.stack.nl/~dimitri/doxygen/diagrams.html

    And here http://www.graphviz.org/Download_windows.php for the actual thing. Then it's a matter of configuring Doxygen... which I don't remember how. But it isn't hard.

    Naturally... you can also opt to not generate those graphs and diagrams making also sure you have HAVE_DOT set to NO on doxygen configuration.
    Originally Posted by brewbuck:
    Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.

  3. #3
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Actually, I wanted to keep it separate since comments take up a huge portion of lines in the code.
    And generally, I do like function prototypes to be spaced together, after each other, since it enhances readability.
    But thanks for the links. I'm going to check it out tomorrow.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  4. #4
    Frequently Quite Prolix dwks's Avatar
    Join Date
    Apr 2005
    Location
    Canada
    Posts
    8,057
    Note that with Doxygen, you can put the documentation for any entity anywhere. There are special commands, like @file or \file, which let you refer to exactly what it is you are documenting. (Commands exist for referring to functions, classes, variables, etc, I just don't know them offhand.)

    Personally, I would recommend putting your documentation throughout your code for several reasons.
    • Doxygen comments are often quite technical, and would be very useful for people reading your code. People don't like to switch between files all of the time. These comments are much more likely to be used if they're conveniently placed right at the entities they document.
    • Putting your comments elsewhere means that you have to basically duplicate the signatures of your functions or whatever in another file, making renaming functions or other identifiers that much harder.
    • It's not that big of a hassle to put the comments inline. With syntax highlighting, you can easily skip over large sections of commenting. You can also use code folding as Mario F. suggested. (I think he suggested syntax highlighting, too.)

    Also see this, from the Doxygen manual: http://www.stack.nl/~dimitri/doxygen/docblocks.html
    Documentation at other places
    So far we have assumed that the documentation blocks are always located in front of the declaration or definition of a file, class or namespace or in front or after one of its members. Although this is often comfortable, there may sometimes be reasons to put the documentation somewhere else. For documenting a file this is even required since there is no such thing as "in front of a file".

    Doxygen allows you to put your documentation blocks practically anywhere (the exception is inside the body of a function or inside a normal C style comment block).

    The price you pay for not putting the documentation block directly before (or after) an item is the need to put a structural command inside the documentation block, which leads to some duplication of information. So in practice you should avoid the use of structural commands unless other requirements force you to do so.
    Italics are theirs, not mine.
    dwk

    Seek and ye shall find. quaere et invenies.

    "Simplicity does not precede complexity, but follows it." -- Alan Perlis
    "Testing can only prove the presence of bugs, not their absence." -- Edsger Dijkstra
    "The only real mistake is the one from which we learn nothing." -- John Powell


    Other boards: DaniWeb, TPS
    Unofficial Wiki FAQ: cpwiki.sf.net

    My website: http://dwks.theprogrammingsite.com/
    Projects: codeform, xuni, atlantis, nort, etc.

  5. #5
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    OK, I got it compiling and generating documentation and all that, but the errors mentioned above is still there. Not to mention, for example, it calls CMemoryManagerBase as "abstract< T > Class Template Reference".
    And also, if I tell it to just compile documented functions, it shows nothing at all, even though I put a proper comment block before a function and even included the test class on the manual page!
    The how of using doxygen still escapes me.
    Last edited by Elysia; 04-14-2008 at 01:08 AM.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  6. #6
    (?<!re)tired Mario F.'s Avatar
    Join Date
    May 2006
    Location
    Ireland
    Posts
    8,446
    I've ran into some problem with templates and doxygen in the past too. Some issues are still unsolved as you can gather from the documentation and other sources on the website. Others can be solved by slightly altering the placement of your declarations in relation to the definitions. (In fact Doxygen likes it when you predeclare everything).

    I'm unsure as to what your problem may be. The template seems simple enough to not cause any trouble. The only thing I can think of is for you to predeclare that template class and see how doxygen behaves. If you do, you may want to comment not the declaration, but the definitions themselves. You may want also to play with some of the Doxygen documentation specifiers like /brief. You will want to red about these. They will keep Doxygen greedy parser under control.

    You are not alone. Doxygen takes some time to get used to its idiosyncrasies. You'll learn these quickly enough if you press on, read carefully the documentation, subscribe to the mailing list and experiment. It keeps getting fixed which is good, but its still a tool that can make you want to pull your hairs out in frustration.

    Unfortunately I can't help you past this. It's been a good while since I last used Doxygen. I can't remember many of the details. All I can say is that it works. You just need to look at it as a tool a tad bit more complicated than it would appear at first sight, and which will demand some study in the beginning in order to allow you to rip the benefits.
    Originally Posted by brewbuck:
    Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.

  7. #7
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    I always like to declare/define templates before the actual implementation. Indeed, I have a full definition of all the template classes before the implementation in each file for the class.

    But I still don't understand how to get it properly working. I've managed to make it detect classes, but not functions. Inside or outside a namespace, it doesn't matter.

    This works:
    Code:
    //! A namespace...
    /*!
    A more elaborate description of the namespace.
    */	
    namespace Stuff
    {
    	//! A constructor.
    	/*!
    	A more elaborate description of the class.
    	*/	
    	class CTest
    	{
    	public:
    		//! Some stupid member function.
    		/*!
    		A more elaborate description of the function.
    		*/	
    		EXPORT StringVector StandardOpen(const CString& strDefExt, const CString& strFileName, const CString& strFilter, bool bMulti, CWnd* pParentWnd = NULL);
    	}
    }
    
    #endif // Test_h__
    Now remove that class:
    Code:
    //! A namespace...
    /*!
    A more elaborate description of the namespace.
    */	
    namespace Stuff
    {
    	//! A constructor.
    	/*!
    	A more elaborate description of the class.
    	*/	
    	//! Some stupid member function.
    	/*!
    	A more elaborate description of the function.
    	*/	
    	EXPORT StringVector StandardOpen(const CString& strDefExt, const CString& strFileName, const CString& strFilter, bool bMulti, CWnd* pParentWnd = NULL);
    }
    
    #endif // Test_h__
    Suddenly it stops working.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  8. #8
    Frequently Quite Prolix dwks's Avatar
    Join Date
    Apr 2005
    Location
    Canada
    Posts
    8,057
    Maybe it's that EXPORT thing. What happens if you get rid of it?

    However, I was able to parse that. Here's my input and output.
    Code:
    $ cat test-original.cpp 
    //! A namespace...
    /*!
    A more elaborate description of the namespace.
    */	
    namespace Stuff
    {
    	//! A constructor.
    	/*!
    	A more elaborate description of the class.
    	*/	
    	class CTest
    	{
    	public:
    		//! Some stupid member function.
    		/*!
    		A more elaborate description of the function.
    		*/	
    		EXPORT StringVector StandardOpen(const CString& strDefExt, const CString& strFileName, const CString& strFilter, \
    bool bMulti, CWnd* pParentWnd = NULL);
    	}
    }
    
    $ cat test-noclass.cpp 
    //! A namespace...
    /*!
    A more elaborate description of the namespace.
    */	
    namespace Stuff
    {
    	//! A constructor.
    	/*!
    	A more elaborate description of the class.
    	*/	
    	//! Some stupid member function.
    	/*!
    	A more elaborate description of the function.
    	*/	
    	EXPORT StringVector StandardOpen(const CString& strDefExt, const CString& strFileName, const CString& strFilter, \
    bool bMulti, CWnd* pParentWnd = NULL);
    }
    
    $ doxygen -s -g
    
    
    Configuration file `Doxyfile' created.
    
    Now edit the configuration file and enter
    
      doxygen Doxyfile
    
    to generate the documentation for your project
    
    $ cat Doxyfile 
    # Doxyfile 1.5.5
    
    #---------------------------------------------------------------------------
    # Project related configuration options
    #---------------------------------------------------------------------------
    DOXYFILE_ENCODING      = UTF-8
    PROJECT_NAME           = 
    PROJECT_NUMBER         = 
    OUTPUT_DIRECTORY       = 
    CREATE_SUBDIRS         = NO
    OUTPUT_LANGUAGE        = English
    BRIEF_MEMBER_DESC      = YES
    REPEAT_BRIEF           = YES
    ABBREVIATE_BRIEF       = 
    ALWAYS_DETAILED_SEC    = NO
    INLINE_INHERITED_MEMB  = NO
    FULL_PATH_NAMES        = YES
    STRIP_FROM_PATH        = 
    STRIP_FROM_INC_PATH    = 
    SHORT_NAMES            = NO
    JAVADOC_AUTOBRIEF      = NO
    QT_AUTOBRIEF           = NO
    MULTILINE_CPP_IS_BRIEF = NO
    DETAILS_AT_TOP         = NO
    INHERIT_DOCS           = YES
    SEPARATE_MEMBER_PAGES  = NO
    TAB_SIZE               = 8
    ALIASES                = 
    OPTIMIZE_OUTPUT_FOR_C  = NO
    OPTIMIZE_OUTPUT_JAVA   = NO
    OPTIMIZE_FOR_FORTRAN   = NO
    OPTIMIZE_OUTPUT_VHDL   = NO
    BUILTIN_STL_SUPPORT    = NO
    CPP_CLI_SUPPORT        = NO
    SIP_SUPPORT            = NO
    DISTRIBUTE_GROUP_DOC   = NO
    SUBGROUPING            = YES
    TYPEDEF_HIDES_STRUCT   = NO
    #---------------------------------------------------------------------------
    # Build related configuration options
    #---------------------------------------------------------------------------
    EXTRACT_ALL            = NO
    EXTRACT_PRIVATE        = NO
    EXTRACT_STATIC         = NO
    EXTRACT_LOCAL_CLASSES  = YES
    EXTRACT_LOCAL_METHODS  = NO
    EXTRACT_ANON_NSPACES   = NO
    HIDE_UNDOC_MEMBERS     = NO
    HIDE_UNDOC_CLASSES     = NO
    HIDE_FRIEND_COMPOUNDS  = NO
    HIDE_IN_BODY_DOCS      = NO
    INTERNAL_DOCS          = NO
    CASE_SENSE_NAMES       = YES
    HIDE_SCOPE_NAMES       = NO
    SHOW_INCLUDE_FILES     = YES
    INLINE_INFO            = YES
    SORT_MEMBER_DOCS       = YES
    SORT_BRIEF_DOCS        = NO
    SORT_GROUP_NAMES       = NO
    SORT_BY_SCOPE_NAME     = NO
    GENERATE_TODOLIST      = YES
    GENERATE_TESTLIST      = YES
    GENERATE_BUGLIST       = YES
    GENERATE_DEPRECATEDLIST= YES
    ENABLED_SECTIONS       = 
    MAX_INITIALIZER_LINES  = 30
    SHOW_USED_FILES        = YES
    SHOW_DIRECTORIES       = NO
    FILE_VERSION_FILTER    = 
    #---------------------------------------------------------------------------
    # configuration options related to warning and progress messages
    #---------------------------------------------------------------------------
    QUIET                  = NO
    WARNINGS               = YES
    WARN_IF_UNDOCUMENTED   = YES
    WARN_IF_DOC_ERROR      = YES
    WARN_NO_PARAMDOC       = NO
    WARN_FORMAT            = "$file:$line: $text"
    WARN_LOGFILE           = 
    #---------------------------------------------------------------------------
    # configuration options related to the input files
    #---------------------------------------------------------------------------
    INPUT                  = 
    INPUT_ENCODING         = UTF-8
    FILE_PATTERNS          = 
    RECURSIVE              = NO
    EXCLUDE                = 
    EXCLUDE_SYMLINKS       = NO
    EXCLUDE_PATTERNS       = 
    EXCLUDE_SYMBOLS        = 
    EXAMPLE_PATH           = 
    EXAMPLE_PATTERNS       = 
    EXAMPLE_RECURSIVE      = NO
    IMAGE_PATH             = 
    INPUT_FILTER           = 
    FILTER_PATTERNS        = 
    FILTER_SOURCE_FILES    = NO
    #---------------------------------------------------------------------------
    # configuration options related to source browsing
    #---------------------------------------------------------------------------
    SOURCE_BROWSER         = NO
    INLINE_SOURCES         = NO
    STRIP_CODE_COMMENTS    = YES
    REFERENCED_BY_RELATION = NO
    REFERENCES_RELATION    = NO
    REFERENCES_LINK_SOURCE = YES
    USE_HTAGS              = NO
    VERBATIM_HEADERS       = YES
    #---------------------------------------------------------------------------
    # configuration options related to the alphabetical class index
    #---------------------------------------------------------------------------
    ALPHABETICAL_INDEX     = NO
    COLS_IN_ALPHA_INDEX    = 5
    IGNORE_PREFIX          = 
    #---------------------------------------------------------------------------
    # configuration options related to the HTML output
    #---------------------------------------------------------------------------
    GENERATE_HTML          = YES
    HTML_OUTPUT            = html
    HTML_FILE_EXTENSION    = .html
    HTML_HEADER            = 
    HTML_FOOTER            = 
    HTML_STYLESHEET        = 
    HTML_ALIGN_MEMBERS     = YES
    GENERATE_HTMLHELP      = NO
    GENERATE_DOCSET        = NO
    DOCSET_FEEDNAME        = "Doxygen generated docs"
    DOCSET_BUNDLE_ID       = org.doxygen.Project
    HTML_DYNAMIC_SECTIONS  = NO
    CHM_FILE               = 
    HHC_LOCATION           = 
    GENERATE_CHI           = NO
    BINARY_TOC             = NO
    TOC_EXPAND             = NO
    DISABLE_INDEX          = NO
    ENUM_VALUES_PER_LINE   = 4
    GENERATE_TREEVIEW      = NO
    TREEVIEW_WIDTH         = 250
    #---------------------------------------------------------------------------
    # configuration options related to the LaTeX output
    #---------------------------------------------------------------------------
    GENERATE_LATEX         = YES
    LATEX_OUTPUT           = latex
    LATEX_CMD_NAME         = latex
    MAKEINDEX_CMD_NAME     = makeindex
    COMPACT_LATEX          = NO
    PAPER_TYPE             = a4wide
    EXTRA_PACKAGES         = 
    LATEX_HEADER           = 
    PDF_HYPERLINKS         = YES
    USE_PDFLATEX           = YES
    LATEX_BATCHMODE        = NO
    LATEX_HIDE_INDICES     = NO
    #---------------------------------------------------------------------------
    # configuration options related to the RTF output
    #---------------------------------------------------------------------------
    GENERATE_RTF           = NO
    RTF_OUTPUT             = rtf
    COMPACT_RTF            = NO
    RTF_HYPERLINKS         = NO
    RTF_STYLESHEET_FILE    = 
    RTF_EXTENSIONS_FILE    = 
    #---------------------------------------------------------------------------
    # configuration options related to the man page output
    #---------------------------------------------------------------------------
    GENERATE_MAN           = NO
    MAN_OUTPUT             = man
    MAN_EXTENSION          = .3
    MAN_LINKS              = NO
    #---------------------------------------------------------------------------
    # configuration options related to the XML output
    #---------------------------------------------------------------------------
    GENERATE_XML           = NO
    XML_OUTPUT             = xml
    XML_SCHEMA             = 
    XML_DTD                = 
    XML_PROGRAMLISTING     = YES
    #---------------------------------------------------------------------------
    # configuration options for the AutoGen Definitions output
    #---------------------------------------------------------------------------
    GENERATE_AUTOGEN_DEF   = NO
    #---------------------------------------------------------------------------
    # configuration options related to the Perl module output
    #---------------------------------------------------------------------------
    GENERATE_PERLMOD       = NO
    PERLMOD_LATEX          = NO
    PERLMOD_PRETTY         = YES
    PERLMOD_MAKEVAR_PREFIX = 
    #---------------------------------------------------------------------------
    # Configuration options related to the preprocessor   
    #---------------------------------------------------------------------------
    ENABLE_PREPROCESSING   = YES
    MACRO_EXPANSION        = NO
    EXPAND_ONLY_PREDEF     = NO
    SEARCH_INCLUDES        = YES
    INCLUDE_PATH           = 
    INCLUDE_FILE_PATTERNS  = 
    PREDEFINED             = 
    EXPAND_AS_DEFINED      = 
    SKIP_FUNCTION_MACROS   = YES
    #---------------------------------------------------------------------------
    # Configuration::additions related to external references   
    #---------------------------------------------------------------------------
    TAGFILES               = 
    GENERATE_TAGFILE       = 
    ALLEXTERNALS           = NO
    EXTERNAL_GROUPS        = YES
    PERL_PATH              = /usr/bin/perl
    #---------------------------------------------------------------------------
    # Configuration options related to the dot tool   
    #---------------------------------------------------------------------------
    CLASS_DIAGRAMS         = YES
    MSCGEN_PATH            = 
    HIDE_UNDOC_RELATIONS   = YES
    HAVE_DOT               = NO
    CLASS_GRAPH            = YES
    COLLABORATION_GRAPH    = YES
    GROUP_GRAPHS           = YES
    UML_LOOK               = NO
    TEMPLATE_RELATIONS     = NO
    INCLUDE_GRAPH          = YES
    INCLUDED_BY_GRAPH      = YES
    CALL_GRAPH             = NO
    CALLER_GRAPH           = NO
    GRAPHICAL_HIERARCHY    = YES
    DIRECTORY_GRAPH        = YES
    DOT_IMAGE_FORMAT       = png
    DOT_PATH               = 
    DOTFILE_DIRS           = 
    DOT_GRAPH_MAX_NODES    = 50
    MAX_DOT_GRAPH_DEPTH    = 0
    DOT_TRANSPARENT        = YES
    DOT_MULTI_TARGETS      = NO
    GENERATE_LEGEND        = YES
    DOT_CLEANUP            = YES
    #---------------------------------------------------------------------------
    # Configuration::additions related to the search engine   
    #---------------------------------------------------------------------------
    SEARCHENGINE           = NO
    $ doxygen
    Searching for include files...
    Searching for example files...
    Searching for images...
    Searching for dot files...
    Searching for files to exclude
    Searching for files to process...
    Searching for files in directory /home/dwk/c/cb/elysia/doxygen
    Reading and parsing tag files
    Preprocessing /home/dwk/c/cb/elysia/doxygen/test-noclass.cpp...
    Parsing file /home/dwk/c/cb/elysia/doxygen/test-noclass.cpp...
    Preprocessing /home/dwk/c/cb/elysia/doxygen/test-original.cpp...
    Parsing file /home/dwk/c/cb/elysia/doxygen/test-original.cpp...
    Building group list...
    Building directory list...
    Building namespace list...
    Building file list...
    Searching for included using directives...
    Building class list...
    Associating documentation with classes...
    Computing nesting relations for classes...
    Searching for members imported via using declarations...
    Building example list...
    Searching for enumerations...
    Searching for documented variables...
    Building member list...
    Searching for friends...
    Searching for documented defines...
    Computing class inheritance relations...
    Computing class usage relations...
    Flushing cached template relations that have become invalid...
    Creating members for template instances...
    Computing class relations...
    Searching for member function documentation...
    Building page list...
    Search for main page...
    Computing page relations...
    Determining the scope of groups...
    Sorting lists...
    Freeing entry tree
    Determining which enums are documented
    Computing member relations...
    Building full member lists recursively...
    Adding members to member groups.
    Computing member references...
    Inheriting documentation...
    Generating disk names...
    Adding source references...
    Adding todo/test/bug list items...
    Counting data structures...
    Resolving user defined references...
    Finding anchors and sections in the documentation...
    Combining using relations...
    Generating style sheet...
    Generating index page...
    Generating page index...
    Generating example documentation...
    Generating file sources...
    Generating file documentation...
    Generating page documentation...
    Generating group documentation...
    Generating group index...
    Generating class documentation...
    Generating annotated compound index...
    Generating hierarchical class index...
    Generating member index...
    Generating namespace index...
    Generating docs for namespace Stuff
    Generating docs for compound Stuff::CTest...
    Generating namespace member index...
    Generating graph info page...
    Generating file index...
    Generating example index...
    Generating file member index...
    $ ls
    Doxyfile  html  latex  test-noclass.cpp  test-original.cpp
    $ ls html
    annotated.html                    functions.html              tab_b.gif
    classStuff_1_1CTest.html          index.html                  tab_l.gif
    classStuff_1_1CTest-members.html  namespacemembers_func.html  tab_r.gif
    doxygen.css                       namespacemembers.html       tabs.css
    doxygen.png                       namespaces.html
    functions_func.html               namespaceStuff.html
    $
    No troubles there.

    What exactly are you doing? If you're using the command-line only, can you post your whole output of everything from start to finish, not just of running Doxygen, so that I can try it myself? What version of Doxygen are you using? What happens when you try that Doxyfile that I automatically generated above?

    [edit] Do you not limit yourself to a number of characters per line or something? I've trimmed the output with backslashes. [/edit]
    Last edited by dwks; 04-15-2008 at 02:03 PM.
    dwk

    Seek and ye shall find. quaere et invenies.

    "Simplicity does not precede complexity, but follows it." -- Alan Perlis
    "Testing can only prove the presence of bugs, not their absence." -- Edsger Dijkstra
    "The only real mistake is the one from which we learn nothing." -- John Powell


    Other boards: DaniWeb, TPS
    Unofficial Wiki FAQ: cpwiki.sf.net

    My website: http://dwks.theprogrammingsite.com/
    Projects: codeform, xuni, atlantis, nort, etc.

  9. #9
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    The EXPORT doesn't seem to make a difference. And as you should know, I loathe command lines, so I'm running it from the GUI.
    Replacing the file with your file and tweaking some settings to no class diagram (save time), no latex stuff, selecting source & dest directories and running it doesn't seem to help either.
    I'm using 1.5.5. Doxygen seems to be a real bastard to get working.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  10. #10
    Frequently Quite Prolix dwks's Avatar
    Join Date
    Apr 2005
    Location
    Canada
    Posts
    8,057
    And as you should know, I loathe command lines, so I'm running it from the GUI.
    Yes, I thought you would be. It shouldn't really make much difference anyway.

    I'm using 1.5.5.
    Well, as you can see, that's my version too.

    Doxygen seems to be a real bastard to get working.
    On Linux, it was already installed. Presumably you're using Windows, so that might be a bit harder (although when I installed Doxygen 1.4.6 on Windows a while ago, I had no problems whatsoever).

    You didn't try compiling Doxygen from source or anything, right? You just downloaded the binaries here? http://www.stack.nl/~dimitri/doxygen/download.html
    A binary distribution for Windows 95/98/ME/NT/2000/XP/Vista
    doxygen-1.5.5-setup.exe (6.5M)
    Also see these notes, though they're probably not useful. http://www.stack.nl/~dimitri/doxygen...ll_bin_windows
    dwk

    Seek and ye shall find. quaere et invenies.

    "Simplicity does not precede complexity, but follows it." -- Alan Perlis
    "Testing can only prove the presence of bugs, not their absence." -- Edsger Dijkstra
    "The only real mistake is the one from which we learn nothing." -- John Powell


    Other boards: DaniWeb, TPS
    Unofficial Wiki FAQ: cpwiki.sf.net

    My website: http://dwks.theprogrammingsite.com/
    Projects: codeform, xuni, atlantis, nort, etc.

  11. #11
    Frequently Quite Prolix dwks's Avatar
    Join Date
    Apr 2005
    Location
    Canada
    Posts
    8,057
    Alright, so I download the Windows installer and ran it in wine (since I'm using Linux). I installed using all the default options, except that I chose not to create a start menu item. I used the GUI to create a Doxyfile, with basically the default options (I just added the paths, to the source code and working directory and so on).

    I then ran Doxygen (again, this is all from the GUI). I got an error about not being able to execute dot, of course, just like you did. But I didn't get an error about unique matches, and the HTML documentation was all generated correctly.

    Elysia, can you please post the smallest snippet you can create (even if it's big, I don't really care) that will cause Doxygen to fail? I'm guessing you're trying to parse more code than you have.

    I don't know if it's a Doxygen problem, but maybe it is. It might be something wrong with your code, I guess -- does it compile without warnings?
    dwk

    Seek and ye shall find. quaere et invenies.

    "Simplicity does not precede complexity, but follows it." -- Alan Perlis
    "Testing can only prove the presence of bugs, not their absence." -- Edsger Dijkstra
    "The only real mistake is the one from which we learn nothing." -- John Powell


    Other boards: DaniWeb, TPS
    Unofficial Wiki FAQ: cpwiki.sf.net

    My website: http://dwks.theprogrammingsite.com/
    Projects: codeform, xuni, atlantis, nort, etc.

  12. #12
    (?<!re)tired Mario F.'s Avatar
    Join Date
    May 2006
    Location
    Ireland
    Posts
    8,446
    I'm guessing this is a problem with namespaces, not the template class itself. I suggest perhaps trying to reproduce the problem with a similar namespace setting.

    Remember dwks? Doxygen is still shaky around certain namespace setups. I remember one in particular that would drive me nuts; partitioned unnamed namespaces in the header and source file. I don't remember actual parsing errors like Elysia is experimenting, just failing to document the definitions... but one never knows. So probably it is best to include the namespace setup in that test.
    Originally Posted by brewbuck:
    Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.

  13. #13
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Seeing as it failed big time with the real source, I tried to dumb it down to the following:

    Code:
    #ifndef Test_h__
    #define Test_h__
    
    //! A namespace...
    /*!
    A more elaborate description of the namespace.
    */	
    namespace Stuff
    {
    	//! A constructor.
    	/*!
    	A more elaborate description of the class.
    	*/	
    	{
    	public:
    		//! Some stupid member function.
    		/*!
    		A more elaborate description of the function.
    		*/	
    		void StandardOpen(const int& strDefExt, const int& strFileName, const int& strFilter, bool bMulti, long* pParentWnd = NULL);
    	}
    }
    
    #endif // Test_h__
    
    //! Opens a Open File Dialog (deprecated; use StandardOpenV2)
    /*!
    This function opens a standard open file dialog with the supplied arguments. This function is deprecated; use StandardOpenV2 instead.
    \param strDefExt The extension to show by default
    \param strFileName The filename to display by default
    \param strFilter Filter to use (extension|name)
    \param bMulti True if user is allowed to select multiple files
    \param pParentWnd The dialog that is the owner (parent)
    */
    Which is exactly what I showed and what Doxygen seems to be failing at.
    (Actually, I tried changing the types to see if it would help, but it doesn't.)

    The real code compiles w/o warnings and errors, and I'm pretty sure this snippet would too, but I haven't tried it because it's a dummy to try to figure out why doxy is failing.

    I'm pretty sure it must be some setting. Remove the namespace, keep the class. It works. Remove the class. It fails.
    Last edited by Elysia; 04-15-2008 at 11:48 PM.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  14. #14
    Frequently Quite Prolix dwks's Avatar
    Join Date
    Apr 2005
    Location
    Canada
    Posts
    8,057
    Remember dwks? Doxygen is still shaky around certain namespace setups. I remember one in particular that would drive me nuts; partitioned unnamed namespaces in the header and source file. I don't remember actual parsing errors like Elysia is experimenting, just failing to document the definitions... but one never knows. So probably it is best to include the namespace setup in that test.
    Nope, never heard anything about it. I mainly use Doxygen for C, which is probably why.

    Well, I used exactly what you have posted, and it worked. (This is Doxygen running in wine.) Mario F.: I did, actually. I used the entire code posted, with all three of Elysia's snippets.

    I got no warnings, nothing.

    The only thing that I can think of is that perhaps the authors of Doxygen accidentally uploaded a version of Doxygen that was broken, and quickly replaced it with a version that worked -- but not before Elysia downloaded the broken one. (Because when I came along and downloaded it a few days or whatever later, it worked.) Maybe you might want to try downloading Doxygen again, Elysia?
    dwk

    Seek and ye shall find. quaere et invenies.

    "Simplicity does not precede complexity, but follows it." -- Alan Perlis
    "Testing can only prove the presence of bugs, not their absence." -- Edsger Dijkstra
    "The only real mistake is the one from which we learn nothing." -- John Powell


    Other boards: DaniWeb, TPS
    Unofficial Wiki FAQ: cpwiki.sf.net

    My website: http://dwks.theprogrammingsite.com/
    Projects: codeform, xuni, atlantis, nort, etc.

  15. #15
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Quote Originally Posted by dwks View Post
    The only thing that I can think of is that perhaps the authors of Doxygen accidentally uploaded a version of Doxygen that was broken, and quickly replaced it with a version that worked -- but not before Elysia downloaded the broken one. (Because when I came along and downloaded it a few days or whatever later, it worked.) Maybe you might want to try downloading Doxygen again, Elysia?
    No... Tried, no workie.
    OK this sucks. So any alternative to Doxygen? Free or not doesn't matter so long as it works. Which I can't say about Doxygen.
    Obviously free isn't bad, but when it doesn't work then it worse than paid.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 16
    Last Post: 09-23-2008, 03:32 AM
  2. pointer comparison failing
    By Bleech in forum C Programming
    Replies: 4
    Last Post: 08-11-2007, 06:33 PM
  3. CreateDevice failing
    By MadCow257 in forum Game Programming
    Replies: 6
    Last Post: 03-14-2006, 09:03 PM
  4. My library is failing and I cannot figure out why...
    By DerelictDream in forum C++ Programming
    Replies: 7
    Last Post: 08-15-2005, 03:47 PM
  5. initializes all components of failing to false
    By romeoz in forum C++ Programming
    Replies: 21
    Last Post: 08-01-2003, 09:30 PM