d3p*_*3pd 5 c++ warnings doxygen
我是第一次尝试使用 Doxygen。在运行 Doxygen 时,我收到大量以下形式的警告:
<code>.cxx:<行号>:警告:记录的函数“<function>::<function>”未声明或定义。
我不知道如何解决这个问题。我正在使用一个大型 C++ 包,并且在运行 Doxygen 时会出现数百次此类警告。
以下是更具体的信息:
警告示例:
Accept.cxx:14: warning: documented function `Accept::Accept' was not declared or defined.
Run Code Online (Sandbox Code Playgroud)
相应的示例代码部分:
#include "Analysis/Accept.h"
#include "Analysis/Cutflow.h"
#include "GlaNtp/GlaUtil/Steer/Steer.h"
#include <iostream>
Accept::Accept(unsigned int cutmask, unsigned int invertword, StringIntMap* CutTypeMap, Cutflow* analysis_cutflow): m_cutmask(cutmask), m_invertword(invertword),
m_cutword(0),m_cutword_set(false), m_CutTypeMap(CutTypeMap),
m_analysis_cutflow(analysis_cutflow){
// this is constructor
InitBitOrder();
}
Accept::~Accept(){}
void Accept::setCutWord(const unsigned int &cutword){
m_cutword_set = true;
m_cutword = cutword;
}
bool Accept::didBitPass(){
//std::cout << "Rick Evnt Pass: " << rickTestCutWord() << std::endl;
return testCutWord();
}
void Accept::InitBitOrder(){
Steer* bitorsteer=new Steer();
std::string configfile="ConFigFiles/ApplyBits/BitOrderConfigurationFile.txt";
if(!bitorsteer->ReadFile(configfile)){
std::cout << "Fatal ERROR: Failed to read Bit Order configuration steering file: " << configfile << std::endl;
delete bitorsteer;
bitorsteer=0;
exit(1);
}
m_bitOrderMap = new StringIntMap("BitOrder", bitorsteer);// bit order
delete bitorsteer;
}
Run Code Online (Sandbox Code Playgroud)
如果您能为我指明正确的方向,我将不胜感激。
先发制人的感谢
我的猜测是 Doxygen 没有解析Analysis/Accept.h头文件,所以它没有看到Analysis类声明。在输出日志中,检查是否Analysis/Accept.h确实正在处理。
为了确保 Doxygen 解析该Analysis目录,您可能必须在 Expert->Input(在 Doxygen GUI 前端)中添加其他源目录,和/或启用“递归”选项。也许您必须指定比当前指定的源目录高一级的源目录。
| 归档时间: |
|
| 查看次数: |
12605 次 |
| 最近记录: |