doxygen: made the todos visible in the doxygen output

This commit is contained in:
Daniel Marjamäki 2009-07-14 08:17:12 +02:00
parent 17008879ac
commit 4f2520bef3
7 changed files with 23 additions and 23 deletions

View File

@ -273,7 +273,7 @@ void CheckClass::constructors()
className[1] = 0;
const Token *classNameToken = tok1->tokAt(1);
// TODO: handling of private constructors should be improved.
/** @todo handling of private constructors should be improved */
bool hasPrivateConstructor = false;
{
int indentlevel = 0;
@ -312,8 +312,8 @@ void CheckClass::constructors()
if (hasPrivateConstructor)
{
// TODO: Handle private constructors.
// Right now to avoid false positives I just bail out
/** @todo Handle private constructors. Right now to avoid
* false positives we just bail out */
tok1 = Token::findmatch(tok1->next(), pattern_class);
continue;
}
@ -439,9 +439,9 @@ void CheckClass::privateFunctions()
// Locate some class
for (const Token *tok1 = Token::findmatch(_tokenizer->tokens(), "class %var% {"); tok1; tok1 = Token::findmatch(tok1->next(), "class %var% {"))
{
// If the class implementation is incomplete there may be false positives about unused private functions.
// Therefore I only check classes that are declared in the source file.
// Todo: check classes that are declared in header file too. make sure the whole implementation is seen.
/** @todo check that the whole class implementation is seen */
// until the todo above is fixed we only check classes that are
// declared in the source file
if (tok1->fileIndex() != 0)
continue;
@ -456,7 +456,7 @@ void CheckClass::privateFunctions()
{
if (Token::Match(tok, "friend %var%"))
{
// Todo: Handle friend classes
/** @todo Handle friend classes */
FuncList.clear();
break;
}
@ -588,7 +588,6 @@ void CheckClass::noMemset()
if (!Token::Match(tok, "memset|memcpy|memmove"))
continue;
// Todo: Handle memcpy and memmove
const char *type = NULL;
if (Token::Match(tok, "memset ( %var% , %num% , sizeof ( %type% ) )"))
type = tok->strAt(8);

View File

@ -532,7 +532,7 @@ const char * CheckMemoryLeakInFunction::call_func(const Token *tok, std::list<co
func_ = func_->next();
const char *ret = 0;
// TODO : "goto" isn't handled well
/** @todo handle "goto" */
if (Token::findmatch(func_, "dealloc"))
ret = "dealloc";
else if (Token::findmatch(func_, "use"))
@ -1119,7 +1119,6 @@ void CheckMemoryLeakInFunction::simplifycode(Token *tok, bool &all)
done = false;
}
// TODO Make this more generic. Delete "if ; else use ; use"
else if (Token::Match(tok2, "; if ; else assign|use ; assign|use") ||
Token::Match(tok2, "; if assign|use ; else ; assign|use"))
{
@ -1274,7 +1273,7 @@ void CheckMemoryLeakInFunction::simplifycode(Token *tok, bool &all)
}
// Reduce "do { alloc ; } " => "alloc ;"
// TODO: If the loop can be executed twice reduce to "loop alloc ;" instead
/** @todo If the loop "do { alloc ; }" can be executed twice, reduce it to "loop alloc ;" */
if (Token::simpleMatch(tok2->next(), "do { alloc ; }"))
{
Token::eraseTokens(tok2, tok2->tokAt(3));
@ -1552,7 +1551,7 @@ void CheckMemoryLeakInFunction::checkScope(const Token *Tok1, const char varname
return;
}
// TODO : handle "goto"
/** @todo handle "goto" */
if (Token::findmatch(tok, "goto"))
{
Tokenizer::deleteTokens(tok);

View File

@ -233,7 +233,7 @@ public:
void check()
{
// TODO
/** @todo implement this */
}
private:

View File

@ -172,7 +172,8 @@ void CheckUnusedFunctions::check()
}
else if (! func.usedOtherFile)
{
/* TODO - add error message "function is only used in <file> it can be static"
/** @todo add error message "function is only used in <file> it can be static" */
/*
std::ostringstream errmsg;
errmsg << "The function '" << it->first << "' is only used in the file it was declared in so it should have local linkage.";
_errorLogger->reportErr( errmsg.str() );

View File

@ -75,10 +75,12 @@ void Preprocessor::writeError(const std::string &fileName, const std::string &co
// UTF / extended ASCII => The output from the preprocessor should only be standard ASCII
if (ch < 0)
{
// TODO: Remove characters that are redundant
// TODO: Convert characters that are needed to standard ASCII
/**
* @todo handle utf better:
* - remove characters that are redundant
* - convert needed characters to standard ASCII
*/
// Not sure how to handle this character. Bailing out.
if (ch < 0)
continue;
@ -703,7 +705,7 @@ bool Preprocessor::match_cfg_def(std::string cfg, std::string def)
std::string::size_type pos1 = pos + 8;
const std::string par(def.substr(pos1, pos2 - pos1));
// TODO: better checking if parameter is defined
/** @todo better checking if parameter is defined */
const bool isdefined(cfg.find(par) != std::string::npos);
def.erase(pos, pos2 + 1 - pos);

View File

@ -271,7 +271,6 @@ bool Token::Match(const Token *tok, const char pattern[], unsigned int varid)
++p;
// Extract token from pattern..
// TODO: Refactor this so there can't be buffer overflows
char str[500];
char *s = str;
while (*p && *p != ' ')

View File

@ -1247,8 +1247,8 @@ void Tokenizer::simplifyTokenList()
}
else if (Token::simpleMatch(tempToken->next(), "["))
{
// TODO: We need to find closing ], then check for
// dots and arrows "var[some[0]]->other"
/** @todo We need to find closing ], then check for
* dots and arrows "var[some[0]]->other" */
// But for now, just bail out
break;
@ -2823,7 +2823,7 @@ void Tokenizer::fillFunctionList()
}
// If the _functionList functions with duplicate names, remove them
// TODO this will need some better handling
/** @todo handle when functions with the same name */
for (unsigned int func1 = 0; func1 < _functionList.size();)
{
bool hasDuplicates = false;