mirror of
https://github.com/github/codeql.git
synced 2026-04-24 16:25:15 +02:00
Boxed variable query: account for implicit-init variables
This commit is contained in:
@@ -63,7 +63,7 @@ from LocalBoxedVar v
|
||||
where
|
||||
forall(Expr e | e = v.getAnAssignedValue() | e.getType() = v.getPrimitiveType()) and
|
||||
(
|
||||
not v.getDeclExpr().getParent() instanceof EnhancedForStmt or
|
||||
not v.getDeclExpr().hasImplicitInit() or
|
||||
v.getDeclExpr().getParent().(EnhancedForStmt).getExpr().getType().(Array).getComponentType() =
|
||||
v.getPrimitiveType()
|
||||
) and
|
||||
|
||||
Reference in New Issue
Block a user