CodeQL library for C/C++
codeql/cpp-all 6.1.4-dev (changelog, source)
Search

Member predicate ExprEvaluator::allowVariableWithoutInitializer

When evaluating a syntactic subexpression of e, we may consider variable v even though it lacks an initializer. Normally, this is not sound, as uninitialized variables can contain arbitrary data (in fact, a query UninitialisedLocal.ql exists for finding that).

Subclasses may implement this predicate when needed.

predicate allowVariableWithoutInitializer(Expr e, Variable v)