CodeQL library for C/C++
Search

Predicate exprMinVal

Gets the minimum value that this expression could represent, based on its type.

For example, if expr has a signed 32-bit type then the result is -2^31.

Note: Due to the way casts are represented, rather than calling exprMinVal(expr) you will normally want to call exprMinVal(expr.getFullyConverted()).

Import path

import semmle.code.cpp.rangeanalysis.RangeAnalysisUtils
float exprMinVal(Expr expr)