@@ -109,41 +109,23 @@ final private class DiscardableContainer extends Discardable instanceof @contain
109109overlay [ local]
110110final private class DiscardableCfgNode extends Discardable instanceof @py_flow_node {
111111 override string getPath ( ) {
112- exists ( Discardable d | result = d .getPath ( ) |
113- py_flow_bb_node ( this , d .( @py_ast_node) , _, _)
114- or
115- py_scope_flow ( this , d .( @py_scope) , _)
116- )
112+ exists ( Discardable d | result = d .getPath ( ) | py_flow_bb_node ( this , d .( @py_ast_node) , _, _) )
117113 }
118114}
119115
120116/** Discardable Python variables. */
121117overlay [ local]
122118final private class DiscardableVar extends Discardable instanceof @py_variable {
123119 override string getPath ( ) {
124- exists ( Discardable parent | result = parent .getPath ( ) |
125- variable ( this , parent .( @py_scope) , _)
126- or
127- py_variables ( this , parent .( @py_variable_parent) )
128- )
120+ exists ( Discardable parent | result = parent .getPath ( ) | variable ( this , parent .( @py_scope) , _) )
129121 }
130122}
131123
132124/** Discardable SSA variables. */
133125overlay [ local]
134126final private class DiscardableSsaVar extends Discardable instanceof @py_ssa_var {
135127 override string getPath ( ) {
136- exists ( DiscardableSsaVar other | result = other .getPath ( ) |
137- py_ssa_phi ( this , other .( @py_ssa_var) )
138- )
139- or
140128 exists ( DiscardableVar other | result = other .getPath ( ) | py_ssa_var ( this , other ) )
141- or
142- exists ( DiscardableCfgNode node | result = node .getPath ( ) |
143- py_ssa_use ( node , this )
144- or
145- py_ssa_defn ( this , node )
146- )
147129 }
148130}
149131
0 commit comments