doxygen为基类函数生成了一个奇怪的错误
这是代码:
namespace Test {
/// Base class
class Base
{
public:
/// Method foo
/// @param a ParamA
/// @param b ParamB
virtual void foo(char a, int b);
/// Method foo
/// @param a ParamA
/// @param b ParamB
/// @param c ParamC
virtual void foo(char a, int b, char c);
/// Method foo
/// @param m ParamM
template<typename T>
void foo(std::vector<T> m)
{
}
};
/// Derived class
class Derived : public Base
{
public:
using Base::foo;
/// Method foo
/// @param a ParamA
/// @param b ParamB
void foo(char a, int b) override;
};
}
如果将使用doxygen处理此代码。我们得到奇怪的错误:
错误:在test :: derived :: foo(typeName t)的参数列表中找不到命令@param的参数'm'(警告被视为错误,立即中止)
如果使用base 使用base :: foo;
doxygen正确处理此文件。
看起来像Doxygen中的错误,但是有人知道解决方案吗?
Here is the code:
namespace Test {
/// Base class
class Base
{
public:
/// Method foo
/// @param a ParamA
/// @param b ParamB
virtual void foo(char a, int b);
/// Method foo
/// @param a ParamA
/// @param b ParamB
/// @param c ParamC
virtual void foo(char a, int b, char c);
/// Method foo
/// @param m ParamM
template<typename T>
void foo(std::vector<T> m)
{
}
};
/// Derived class
class Derived : public Base
{
public:
using Base::foo;
/// Method foo
/// @param a ParamA
/// @param b ParamB
void foo(char a, int b) override;
};
}
If this code will be processed with Doxygen. We get the strange error:
Error: argument 'm' of command @param is not found in the argument list of Test::Derived::foo(typename T) (warning treated as error, aborting now)
If commenting line using Base::foo;
the Doxygen correctly processing this file.
Looks like a bug in Doxygen, but is anybody know a workaround for that?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
当前的doxygen版本是1.9.4(5D15657A555555E6181A7830A5C723AF75E7577E2)
此问题的解决方案是将您的doxygen版本更新为当前doxygen版本。
The current doxygen version is 1.9.4 (5d15657a55555e6181a7830a5c723af75e7577e2)
The solution for this problem is to update your doxygen version to the current doxygen version.