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

Function setSourceLocation

lib/vf_common.cpp:382–393  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

380 }
381
382 void setSourceLocation(Value& v,
383 SourceLocation ctx,
384 const Token* tok,
385 SourceLocation local)
386 {
387 std::string file = ctx.file_name();
388 if (file.empty())
389 return;
390 std::string s = Path::stripDirectoryPart(file) + ":" + std::to_string(ctx.line()) + ": " + ctx.function_name() +
391 " => " + local.function_name() + ": " + debugString(v);
392 v.debugPath.emplace_back(tok, std::move(s));
393 }
394
395 MathLib::bigint valueFlowGetStrLength(const Token* tok, const Settings& settings)
396 {

Callers 7

setTokenValueFunction · 0.85
valueFlowForwardFunction · 0.85
valueFlowReverseFunction · 0.85
byRefMethod · 0.85
byValMethod · 0.85
makeConditionValueFunction · 0.85

Calls 5

debugStringFunction · 0.85
file_nameMethod · 0.80
function_nameMethod · 0.80
emptyMethod · 0.45
lineMethod · 0.45

Tested by

no test coverage detected