Rules: Allow that 'raw' tokens are checked.

This commit is contained in:
Daniel Marjamäki 2013-06-09 15:50:43 +02:00
parent 537166cf47
commit 66f9e9b16f
1 changed files with 11 additions and 0 deletions

View File

@ -317,6 +317,17 @@ void CppCheck::checkFile(const std::string &code, const char FileName[])
try {
bool result;
// Execute rules for "raw" code
for (std::list<Settings::Rule>::const_iterator it = _settings.rules.begin(); it != _settings.rules.end(); ++it) {
if (it->tokenlist == "raw") {
Tokenizer tokenizer2(&_settings, this);
std::istringstream istr(code);
tokenizer2.list.createTokens(istr, FileName);
executeRules("raw", tokenizer2);
break;
}
}
// Tokenize the file
std::istringstream istr(code);