We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f76cde3 commit 7f6ae8bCopy full SHA for 7f6ae8b
1 file changed
python/ql/lib/semmle/python/dataflow/new/internal/DataFlowPrivate.qll
@@ -445,13 +445,11 @@ module StepRelationTransformations {
445
*/
446
module IncludePostUpdateFlow<stepSig/2 rawStep> {
447
predicate step(Node nodeFrom, Node nodeTo) {
448
- // If a raw step can be taken out of a node `node`, a step can be taken
449
- // both out of `node` and any post-update node of `node`.
450
- exists(Node node | rawStep(node, nodeTo) |
451
- nodeFrom = node
452
- or
453
- nodeFrom.(PostUpdateNode).getPreUpdateNode() = node
454
- )
+ // We either have a raw step from `nodeFrom`...
+ rawStep(nodeFrom, nodeTo)
+ or
+ // ...or we have a raw step from a pre-update node of `nodeFrom`
+ rawStep(nodeFrom.(PostUpdateNode).getPreUpdateNode(), nodeTo)
455
}
456
457
0 commit comments