Code cleanup for "membersManager" package to make it type-safe

PullUp: Refactored to use Processor on MembersManager

StatementList refactoring

PullUp: processor added

PyExtractSuperClass and PyPullMembersUp refactored and covered with tests.

PyExtractSuperClass and PyPullMembersUp refactored and covered with tests.
This commit is contained in:
Ilya.Kazakevich
2014-02-04 14:59:06 +04:00
parent c07a1297d8
commit 24c879c5f5
66 changed files with 2053 additions and 1019 deletions

View File

@@ -0,0 +1,21 @@
class Parent(object):
C = 12
def foo(self):
pass
def __init__(self):
self.foo = 12
class Child(Parent, object):
def __init__(self): pass
AC = 11
def foo(self):
pass
class Bar(object):
pass

View File

@@ -0,0 +1,19 @@
class Parent(object):
C = 12
def foo(self):
pass
class Child(Parent, object):
def __init__(self):
self.foo = 12
AC = 11
def foo(self):
pass
class Bar(object):
pass

View File

@@ -52,4 +52,11 @@ class HugeChild(SubParent1, date): #SubParent1 is disabled
@staticmethod
def bad_method(): #Code has errors, so method should be not be marked as static
pass
pass
class Bar(object):
C = 1
class Foo(Bar):
def __init__(self):
self.foo = 12