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

Predicate exprMightOverflowNegatively

Holds if the expression might overflow negatively. This predicate does not consider the possibility that the expression might overflow due to a conversion.

Import path

import semmle.code.cpp.rangeanalysis.new.SimpleRangeAnalysis
predicate exprMightOverflowNegatively(Expr expr)