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

Predicate nanExcludingComparison

Holds if guard won’t return the value polarity when either operand is NaN.

Import path

import semmle.code.cpp.rangeanalysis.NanAnalysis
predicate nanExcludingComparison(ComparisonOperation guard, boolean polarity)