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

Function getVariables

lib/valueflow.cpp:4252–4261  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4250}
4251
4252static std::vector<const Variable*> getVariables(const Token* tok)
4253{
4254 std::vector<const Variable*> result;
4255 visitAstNodes(tok, [&](const Token* child) {
4256 if (child->variable())
4257 result.push_back(child->variable());
4258 return ChildrenToVisit::op1_and_op2;
4259 });
4260 return result;
4261}
4262
4263static void valueFlowAfterSwap(const TokenList& tokenlist,
4264 const SymbolDatabase& symboldatabase,

Callers 2

valueFlowAfterSwapFunction · 0.85
valueFlowSmartPointerFunction · 0.85

Calls 3

visitAstNodesFunction · 0.85
variableMethod · 0.80
push_backMethod · 0.45

Tested by

no test coverage detected