JS: Make implicit this receivers explicit

This commit is contained in:
Kasper Svendsen
2023-05-03 15:31:00 +02:00
parent ea75996932
commit 67950c8e6b
125 changed files with 1061 additions and 1002 deletions

View File

@@ -42,7 +42,7 @@ abstract class EnumeratedPropName extends DataFlow::Node {
* Gets a source node that refers to the object whose properties are being enumerated.
*/
DataFlow::SourceNode getASourceObjectRef() {
result = AccessPath::getAnAliasedSourceNode(getSourceObject())
result = AccessPath::getAnAliasedSourceNode(this.getSourceObject())
}
/**
@@ -53,7 +53,7 @@ abstract class EnumeratedPropName extends DataFlow::Node {
SourceNode getASourceProp() {
exists(Node base, Node key |
dynamicPropReadStep(base, key, result) and
getASourceObjectRef().flowsTo(base) and
this.getASourceObjectRef().flowsTo(base) and
key.getImmediatePredecessor*() = this
)
}