doxygen: Some comments for CheckOther, added @todo to Token::Match

This commit is contained in:
Daniel Marjamäki 2010-03-14 19:11:03 +01:00
parent 933289a6d7
commit 9d822c77aa
2 changed files with 16 additions and 6 deletions

View File

@ -30,19 +30,22 @@ class Token;
/// @addtogroup Checks
/// @{
/** @brief Various small checks */
class CheckOther : public Check
{
public:
/** This constructor is used when registering the CheckClass */
/** @brief This constructor is used when registering the CheckClass */
CheckOther() : Check()
{ }
/** This constructor is used when running checks.. */
/** @brief This constructor is used when running checks.. */
CheckOther(const Tokenizer *tokenizer, const Settings *settings, ErrorLogger *errorLogger)
: Check(tokenizer, settings, errorLogger)
{ }
/** @brief Run checks against the normal token list */
void runChecks(const Tokenizer *tokenizer, const Settings *settings, ErrorLogger *errorLogger)
{
CheckOther checkOther(tokenizer, settings, errorLogger);
@ -59,6 +62,7 @@ public:
}
}
/** @brief Run checks against the simplified token list */
void runSimplifiedChecks(const Tokenizer *tokenizer, const Settings *settings, ErrorLogger *errorLogger)
{
CheckOther checkOther(tokenizer, settings, errorLogger);
@ -84,11 +88,14 @@ public:
}
// TODO move CheckUninitVar?
/**
* @brief Uninitialized variables: analyse functions to see how they work with uninitialized variables
* @param tokens [in] the token list
* @param func [out] names of functions that don't handle uninitialized variables well. the function names are added to the set. No clearing is made.
*/
static void analyseFunctions(const Token * const tokens, std::set<std::string> &func);
// Casting
/** @brief %Check: Are there C-style pointer casts in a c++ file? */
void warningOldStylePointerCast();
// Redundant code

View File

@ -116,6 +116,9 @@ public:
* "const" or "void" and token after that is '{'. If even one of the tokens does not
* match its pattern, false is returned.
*
* @todo pattern "%type%|%num%" should mean either a type or a num.
* @todo pattern "%OR%|%OROR%" should mean either a "|" or a "||"
*
* @param tok List of tokens to be compared to the pattern
* @param pattern The pattern against which the tokens are compared,
* e.g. "const" or ") const|volatile| {".