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

Method valueOfTok_

test/testvalueflow.cpp:539–542  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

537
538#define valueOfTok(...) valueOfTok_(__FILE__, __LINE__, __VA_ARGS__)
539 ValueFlow::Value valueOfTok_(const char* file, int line, const char code[], const char tokstr[], const Settings *s = nullptr, bool cpp = true) {
540 std::list<ValueFlow::Value> values = removeImpossible(tokenValues_(file, line, code, tokstr, s, cpp));
541 return values.size() == 1U && !values.front().isTokValue() ? values.front() : ValueFlow::Value();
542 }
543
544#define testKnownValueOfTok(...) testKnownValueOfTok_(__FILE__, __LINE__, __VA_ARGS__)
545 bool testKnownValueOfTok_(const char* file,

Callers

nothing calls this directly

Calls 4

removeImpossibleFunction · 0.85
frontMethod · 0.80
ValueClass · 0.50
sizeMethod · 0.45

Tested by

no test coverage detected