File tree Expand file tree Collapse file tree 1 file changed +2
-11
lines changed
Expand file tree Collapse file tree 1 file changed +2
-11
lines changed Original file line number Diff line number Diff line change @@ -51,23 +51,14 @@ predicate allocExprOrIndirect(Expr alloc, string kind) {
5151 )
5252}
5353
54- /**
55- * Holds if `v` is a global variable assigned value `e`, and `e` is not known
56- * to be `0`.
57- */
58- private predicate nonNullGlobalAssignment ( Variable v , Expr e ) {
59- not v instanceof LocalScopeVariable and
60- v .getAnAssignedValue ( ) = e and
61- not e .getValue ( ) .toInt ( ) = 0
62- }
63-
6454/**
6555 * Holds if `v` is a non-local variable which is assigned with allocations of
6656 * type `kind`.
6757 */
6858private cached predicate allocReachesVariable ( Variable v , Expr alloc , string kind ) {
6959 exists ( Expr mid |
70- nonNullGlobalAssignment ( v , mid ) and
60+ not v instanceof LocalScopeVariable and
61+ v .getAnAssignedValue ( ) = mid and
7162 allocReaches0 ( mid , alloc , kind )
7263 )
7364}
You can’t perform that action at this time.
0 commit comments