Merge pull request #920 from xiemaisi/js/field-as-prop-write

Approved by asger-semmle
This commit is contained in:
semmle-qlci
2019-02-12 10:48:13 +00:00
committed by GitHub
3 changed files with 19 additions and 2 deletions

View File

@@ -555,14 +555,15 @@ module DataFlow {
}
/**
* An instance field, seen as a property write.
* An instance field with an initializer, seen as a property write.
*/
private class InstanceFieldAsPropWrite extends PropWrite, PropNode {
override FieldDefinition prop;
InstanceFieldAsPropWrite() {
not prop.isStatic() and
not prop instanceof ParameterField
not prop instanceof ParameterField and
exists(prop.getInit())
}
override Node getBase() {