forked from VimPlug/jedi
fix InstanceElement get_commands (doesn't raise an error anymore, but I don't know if it works)
This commit is contained in:
@@ -216,6 +216,8 @@ class InstanceElement(use_metaclass(cache.CachedMetaClass)):
|
|||||||
return func
|
return func
|
||||||
|
|
||||||
def get_commands(self):
|
def get_commands(self):
|
||||||
|
"""
|
||||||
|
# TODO delete ?
|
||||||
# Copy and modify the array.
|
# Copy and modify the array.
|
||||||
origin = self.var.get_commands()
|
origin = self.var.get_commands()
|
||||||
# Delete parent, because it isn't used anymore.
|
# Delete parent, because it isn't used anymore.
|
||||||
@@ -224,6 +226,10 @@ class InstanceElement(use_metaclass(cache.CachedMetaClass)):
|
|||||||
self.is_class_var)
|
self.is_class_var)
|
||||||
new.parent_stmt = par
|
new.parent_stmt = par
|
||||||
return new
|
return new
|
||||||
|
"""
|
||||||
|
# Copy and modify the array.
|
||||||
|
return [InstanceElement(self.instance, command, self.is_class_var)
|
||||||
|
for command in self.var.get_commands()]
|
||||||
|
|
||||||
def __getattr__(self, name):
|
def __getattr__(self, name):
|
||||||
return getattr(self.var, name)
|
return getattr(self.var, name)
|
||||||
|
|||||||
Reference in New Issue
Block a user