Skip to content

Commit 9b493c1

Browse files
committed
Java: Fix bug related to null inference for pattern initializer.
1 parent b005973 commit 9b493c1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

java/ql/lib/semmle/code/java/dataflow/TypeFlow.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ private module Input implements TypeFlowInput<Location> {
138138
exists(LocalVariableDeclExpr decl |
139139
n.asSsa().(BaseSsaUpdate).getDefiningExpr() = decl and
140140
not decl.hasImplicitInit() and
141-
not exists(decl.getInit())
141+
not exists(decl.getInitOrPatternSource())
142142
)
143143
}
144144

0 commit comments

Comments
 (0)