Python: fix QL alerts

This commit is contained in:
Rasmus Lerchedahl Petersen
2022-09-12 23:53:42 +02:00
parent 2e9c60de6c
commit 03c243175b
5 changed files with 5 additions and 11 deletions

View File

@@ -78,7 +78,7 @@ module SyntheticPreUpdateNode {
* that is mapped to the `self` parameter. That way, constructor calls represent the value of the
* object after the constructor (currently only `__init__`) has run.
*/
CfgNode objectCreationNode() { result.getNode().(CallNode) = any(ClassCall c).getNode() }
CfgNode objectCreationNode() { result.getNode() = any(ClassCall c).getNode() }
}
import SyntheticPreUpdateNode

View File

@@ -255,7 +255,7 @@ predicate iterableUnpackingAssignmentFlowStep(Node nodeFrom, Node nodeTo) {
*/
predicate iterableUnpackingForReadStep(CfgNode nodeFrom, Content c, Node nodeTo) {
exists(ForTarget target |
nodeFrom.(CfgNode).getNode().getNode() = target.getSource() and
nodeFrom.getNode().getNode() = target.getSource() and
target instanceof SequenceNode and
nodeTo = TIterableSequenceNode(target)
) and