Files
codeql/cpp/downgrades/625f706f2a44ae8dc3fc168bfe2637e65c30b012/exprs.ql
2022-09-08 10:06:57 +02:00

18 lines
455 B
Plaintext

class Expr extends @expr {
string toString() { none() }
}
class Location extends @location_expr {
string toString() { none() }
}
predicate isExprWithNewBuiltin(Expr expr) {
exists(int kind | exprs(expr, kind, _) | 336 <= kind and kind <= 362)
}
from Expr expr, int kind, int kind_new, Location location
where
exprs(expr, kind, location) and
if isExprWithNewBuiltin(expr) then kind_new = 1 else kind_new = kind
select expr, kind_new, location