Fix compiler warnings about incomplete handling of library error codes
This commit is contained in:
commit
26b699fd30
|
@ -1427,14 +1427,14 @@ bool SymbolDatabase::isFunction(const Token *tok, const Scope* outerScope, const
|
|||
|
||||
void SymbolDatabase::validate() const
|
||||
{
|
||||
if (_settings->debugwarnings) {
|
||||
const std::size_t functions = functionScopes.size();
|
||||
for (std::size_t i = 0; i < functions; ++i) {
|
||||
const Scope* scope = functionScopes[i];
|
||||
const Function* function = scope->function;
|
||||
if (scope->isExecutable() && !function) {
|
||||
if (_settings->debugwarnings) {
|
||||
const std::list<const Token*> callstack(1, scope->classDef);
|
||||
const std::string msg = std::string("executable scope '") + scope->classDef->str() + "' with unknown function";
|
||||
const std::string msg = std::string("Executable scope '") + scope->classDef->str() + "' with unknown function.";
|
||||
const ErrorLogger::ErrorMessage errmsg(callstack, &_tokenizer->list, Severity::debug,
|
||||
"symbolDatabaseWarning",
|
||||
msg,
|
||||
|
|
|
@ -1598,7 +1598,7 @@ private:
|
|||
check("testing::testing()\n"
|
||||
"{\n"
|
||||
"}");
|
||||
ASSERT_EQUALS("[test.cpp:1]: (debug) executable scope 'testing' with unknown function\n", errout.str());
|
||||
ASSERT_EQUALS("[test.cpp:1]: (debug) Executable scope 'testing' with unknown function.\n", errout.str());
|
||||
}
|
||||
|
||||
void symboldatabase5() {
|
||||
|
|
Loading…
Reference in New Issue