Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 92d0aef

Browse files
committed
Rename super_() to superType() for better consistency.
1 parent d44ce4f commit 92d0aef

3 files changed

Lines changed: 5 additions & 5 deletions

File tree

python/ql/src/semmle/python/objects/Instances.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -368,7 +368,7 @@ class SuperInstance extends TSuperInstance, ObjectInternal {
368368
override boolean isClass() { result = false }
369369

370370
override ObjectInternal getClass() {
371-
result = ObjectInternal::super_()
371+
result = ObjectInternal::superType()
372372
}
373373

374374
override boolean isComparable() { result = false }

python/ql/src/semmle/python/objects/ObjectInternal.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -418,7 +418,7 @@ module ObjectInternal {
418418
result = TBuiltinClassObject(Builtin::special("property"))
419419
}
420420

421-
ObjectInternal super_() {
421+
ObjectInternal superType() {
422422
result = TBuiltinClassObject(Builtin::special("super"))
423423
}
424424

python/ql/src/semmle/python/objects/TObject.qll

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ newtype TObject =
121121
}
122122
or
123123
TUnknownInstance(BuiltinClassObjectInternal cls) {
124-
cls != ObjectInternal::super_() and
124+
cls != ObjectInternal::superType() and
125125
cls != ObjectInternal::builtin("bool") and
126126
cls != ObjectInternal::noneType()
127127
}
@@ -208,7 +208,7 @@ pragma [noinline]
208208
private predicate super_call2(CallNode call, ControlFlowNode arg0, ControlFlowNode arg1, PointsToContext context) {
209209
exists(ControlFlowNode func |
210210
call2(call, func, arg0, arg1) and
211-
PointsToInternal::pointsTo(func, context, ObjectInternal::super_(), _)
211+
PointsToInternal::pointsTo(func, context, ObjectInternal::superType(), _)
212212
)
213213
}
214214

@@ -238,7 +238,7 @@ predicate method_binding(AttrNode instantiation, ObjectInternal self, CallableOb
238238
receiver(instantiation, context, obj, name) |
239239
exists(ObjectInternal cls |
240240
cls = obj.getClass() and
241-
cls != ObjectInternal::super_() and
241+
cls != ObjectInternal::superType() and
242242
cls.attribute(name, function, _) and
243243
self = obj
244244
)

0 commit comments

Comments
 (0)