简体   繁体   中英

Doxygen base classes not resolved sometimes

I have a C++ library with several source files documented with Doxygen style comments. In the library, there are three class templates ( Array , Vector , Span ) that all inherit the same base class template ( VctrBase ). I set INLINE_INHERITED_MEMB to YES in the Doxyfile.

The problem

For two of those classes ( Array and Vector ), the rendered documentation shows all inherited base class member functions and the inheritance graph shows the VctrBase base class along with the two base classes of VctrBase . For one class ( Span ) however, this does not work. Especially the inheritance graph shows the base class greyed out and does not show the second inheritance layer as seen in the two other class documentations.

My assumption

I am no doxygen expert, but my guess here is that the dependencies between multiple sourcefiles are not resolved properly. I was under the impression that the order in which source files are processed by doxygen does not matter so even if the Span source file should be parsed before the VctrBase source file things should just work from my knowledge. But I suspect that the error might originate from a misunderstanding about that on my side.

Further information

I'm running Doxygen version 1.9.6 on a GitHub Actions Ubuntu runner. The entire project I'm referencing above is open source and you can have a look at the sources here . For quicker navigation, here are direct links to

In your code, file: include/vctr/Containers/Span.h branch: VCTR-86-Automatically-render-a-doxygen-docu-with-builds you have the line:

template <class ElementType, size_t extent = std::dynamic_extent, class StorageInfoType = StorageInfo<std::span<ElementType, extent>>>
class Span : public VctrBase<ElementType, std::span<ElementType, extent>, extent, StorageInfoType>

and doxygen is apparently confused by the usage of >>> by changing this in > > > so:

template <class ElementType, size_t extent = std::dynamic_extent, class StorageInfoType = StorageInfo<std::span<ElementType, extent> > >
class Span : public VctrBase<ElementType, std::span<ElementType, extent>, extent, StorageInfoType>

I think it gives the results you need.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM