mirror of
https://github.com/github/codeql.git
synced 2026-04-27 17:55:19 +02:00
JS: Add SatisfiesExpr
This commit is contained in:
@@ -334,7 +334,8 @@ module SourceNode {
|
||||
astNode instanceof Templating::PipeRefExpr or
|
||||
astNode instanceof Templating::TemplateVarRefExpr or
|
||||
astNode instanceof StringLiteral or
|
||||
astNode instanceof TypeAssertion
|
||||
astNode instanceof TypeAssertion or
|
||||
astNode instanceof SatisfiesExpr
|
||||
)
|
||||
or
|
||||
exists(VariableDeclarator decl |
|
||||
|
||||
@@ -235,6 +235,8 @@ module TypeResolution {
|
||||
or
|
||||
value.(TypeAssertion).getTypeAnnotation() = type
|
||||
or
|
||||
value.(SatisfiesExpr).getTypeAnnotation() = type
|
||||
or
|
||||
exists(VarDecl decl |
|
||||
// ValueFlow::step is restricted to variables with at most one assignment. Allow the type annotation
|
||||
// of a variable to propagate to its uses, even if the variable has multiple assignments.
|
||||
|
||||
Reference in New Issue
Block a user