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

Method checkVarLifetime

lib/checkautovariables.cpp:708–717  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

706}
707
708void CheckAutoVariablesImpl::checkVarLifetime()
709{
710 logChecker("CheckAutoVariables::checkVarLifetime");
711 const SymbolDatabase *symbolDatabase = mTokenizer->getSymbolDatabase();
712 for (const Scope * scope : symbolDatabase->functionScopes) {
713 if (!scope->function)
714 continue;
715 checkVarLifetimeScope(scope->bodyStart, scope->bodyEnd);
716 }
717}
718
719void CheckAutoVariablesImpl::errorReturnDanglingLifetime(const Token *tok, const ValueFlow::Value *val)
720{

Callers 1

runChecksMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected