mirror of
https://github.com/github/codeql.git
synced 2026-04-28 10:15:14 +02:00
Restrict pattern type guards to account for nested record matching failures
This commit is contained in:
@@ -197,7 +197,7 @@ private module Dispatch {
|
||||
exists(TypeTestGuard typeTest, BaseSsaVariable v, Expr q, RefType t |
|
||||
source.getQualifier() = q and
|
||||
v.getAUse() = q and
|
||||
typeTest.appliesTypeTest(v.getAUse(), t) and
|
||||
typeTest.appliesTypeTest(v.getAUse(), t, false) and
|
||||
guardControls_v1(typeTest, q.getBasicBlock(), false) and
|
||||
tgt.getDeclaringType().getSourceDeclaration().getASourceSupertype*() = t.getErasure()
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user