CodeQL library for JavaScript/TypeScript
codeql/javascript-all 2.2.1-dev (changelog, source)
Search

Predicate inVoidContext

Holds if e appears in a syntactic context where its value is discarded.

Import path

import Expressions.ExprHasNoEffect
predicate inVoidContext(Expr e)