mirror of
https://github.com/github/codeql.git
synced 2025-12-18 01:33:15 +01:00
Exclude error types from contradictory-type-check query
This commit is contained in:
@@ -40,7 +40,9 @@ predicate contradictoryTypeCheck(Expr e, Variable v, RefType t, RefType sup, Exp
|
||||
requiresInstanceOf(e, ssa.getAUse(), t) and
|
||||
sup = t.getAnAncestor() and
|
||||
instanceOfCheck(cond, ssa.getAUse(), sup) and
|
||||
cond.(Guard).controls(e.getBasicBlock(), false)
|
||||
cond.(Guard).controls(e.getBasicBlock(), false) and
|
||||
not t instanceof ErrorType and
|
||||
not sup instanceof ErrorType
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user