3

With the appropriate comment in front of it, Doxygen generates entries for class, struct and namespace declarations but not occurrences of typedef or using.

In this example

/// here is my typedef
typedef int MyTypedef;

/// here is my namespace
namespace MyNamespace 
{
  /// here is my other typedef
  typedef int MyOtherTypedef;
}

I get an entry in the documentation for MyNamespace and even MyOtherTypedef but there is nothing for MyTypedef. Why not?

John McFarlane
  • 5,528
  • 4
  • 34
  • 38

1 Answers1

4

The answer is the same as the answers to why entries for functions and preprocessor definitions are not automatically generated.

Doxygen considers aliases, variables, functions and macros (but not classes or namespaces) to be 'objects'. And all 'objects' are documented iff their containing file, class or namespace is also documented.

For MyTypedef to feature in your documentation, add:

/// \file
/// here is my file

anywhere in the global scope of your file.

Community
  • 1
  • 1
John McFarlane
  • 5,528
  • 4
  • 34
  • 38