mirror of
https://github.com/github/codeql.git
synced 2026-01-06 03:00:24 +01:00
19 lines
388 B
Plaintext
19 lines
388 B
Plaintext
|
|
import python
|
|
import semmle.python.pointsto.MRO
|
|
import semmle.python.pointsto.PointsTo
|
|
import semmle.python.objects.ObjectInternal
|
|
|
|
ClassList mro(ClassObjectInternal cls) {
|
|
if Types::isNewStyle(cls) then
|
|
result = Mro::newStyleMro(cls)
|
|
else
|
|
result = Mro::oldStyleMro(cls)
|
|
}
|
|
|
|
from ClassObjectInternal cls
|
|
where not cls.isBuiltin()
|
|
|
|
select cls.toString(), mro(cls)
|
|
|