MCPcopy Create free account
hub / github.com/cppcheck-opensource/cppcheck / createSymbolDatabaseEscapeFunctions

Method createSymbolDatabaseEscapeFunctions

lib/symboldatabase.cpp:1569–1581  ·  view source on GitHub ↗

cppcheck-suppress functionConst - has side effects

Source from the content-addressed store, hash-verified

1567
1568// cppcheck-suppress functionConst - has side effects
1569void SymbolDatabase::createSymbolDatabaseEscapeFunctions()
1570{
1571 for (const Scope& scope : scopeList) {
1572 if (scope.type != ScopeType::eFunction)
1573 continue;
1574 Function * function = scope.function;
1575 if (!function)
1576 continue;
1577 if (Token::findsimplematch(scope.bodyStart, "return", scope.bodyEnd))
1578 continue;
1579 function->isEscapeFunction(isReturnScope(scope.bodyEnd, mSettings.library, nullptr, true));
1580 }
1581}
1582
1583static bool isExpression(const Token* tok)
1584{

Callers

nothing calls this directly

Calls 2

findsimplematchFunction · 0.85
isReturnScopeFunction · 0.85

Tested by

no test coverage detected