forked from VimPlug/jedi
Self manipulations are now more correct, fixes #1392
This commit is contained in:
@@ -25,3 +25,52 @@ class Sub(Super):
|
||||
|
||||
#! 8 ['class Inner']
|
||||
def Inner(self): pass
|
||||
|
||||
# -----------------
|
||||
# Finding self
|
||||
# -----------------
|
||||
|
||||
class Test1:
|
||||
class Test2:
|
||||
def __init__(self):
|
||||
self.foo_nested = 0
|
||||
#? ['foo_nested']
|
||||
self.foo_
|
||||
#?
|
||||
self.foo_here
|
||||
|
||||
def __init__(self, self2):
|
||||
self.foo_here = 3
|
||||
#? ['foo_here', 'foo_in_func']
|
||||
self.foo_
|
||||
#? int()
|
||||
self.foo_here
|
||||
#?
|
||||
self.foo_nested
|
||||
#?
|
||||
self.foo_not_on_self
|
||||
#? float()
|
||||
self.foo_in_func
|
||||
self2.foo_on_second = ''
|
||||
|
||||
def closure():
|
||||
self.foo_in_func = 4.
|
||||
|
||||
def bar(self):
|
||||
self = 3
|
||||
self.foo_not_on_self = 3
|
||||
|
||||
|
||||
class SubTest(Test1):
|
||||
def __init__(self):
|
||||
self.foo_sub_class = list
|
||||
|
||||
def bar(self):
|
||||
#? ['foo_here', 'foo_in_func', 'foo_sub_class']
|
||||
self.foo_
|
||||
#? int()
|
||||
self.foo_here
|
||||
#?
|
||||
self.foo_nested
|
||||
#?
|
||||
self.foo_not_on_self
|
||||
|
||||
Reference in New Issue
Block a user