I have two classes:
class A {
public:
/** Brief description
* Grand description
*/
virtual void func() {
// Do something.
}
};
class B: public A {
// How to re-describe func() here?
};
I have turned on description inheritance in Doxygen config, and that is fine. But I want to change description in derived class to some functions, implemented in base class, without reimplementing these functions.
Of course, I can do the following:
class B: public A {
public:
/** My new description.
* ...
*/
virtual void func() {
A::func();
}
};
But it seems “ugly” to me – to write unnecessery code just to add some comments.
Are there other solutions?
If you really want to you can also use a preprocessor trick:
along with these settings:
That way only doxygen sees the extra code.