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

Function changePossibleToKnown

lib/valueflow.cpp:186–197  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

184}
185
186static void changePossibleToKnown(std::list<ValueFlow::Value>& values, int indirect = -1)
187{
188 for (ValueFlow::Value& v : values) {
189 if (indirect >= 0 && v.indirect != indirect)
190 continue;
191 if (!v.isPossible())
192 continue;
193 if (v.bound != ValueFlow::Value::Bound::Point)
194 continue;
195 v.setKnown();
196 }
197}
198
199static bool isNonConditionalPossibleIntValue(const ValueFlow::Value& v)
200{

Callers 2

afterConditionMethod · 0.85

Calls 1

isPossibleMethod · 0.80

Tested by

no test coverage detected