From f2a7788d66db67bce28e5065bd022bec24691ce0 Mon Sep 17 00:00:00 2001 From: David Halter Date: Mon, 11 Feb 2013 00:21:05 +0100 Subject: [PATCH] fix InstanceElement get_commands (doesn't raise an error anymore, but I don't know if it works) --- jedi/evaluate_representation.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/jedi/evaluate_representation.py b/jedi/evaluate_representation.py index 10b74dfa..e5f7412c 100644 --- a/jedi/evaluate_representation.py +++ b/jedi/evaluate_representation.py @@ -216,6 +216,8 @@ class InstanceElement(use_metaclass(cache.CachedMetaClass)): return func def get_commands(self): + """ + # TODO delete ? # Copy and modify the array. origin = self.var.get_commands() # Delete parent, because it isn't used anymore. @@ -224,6 +226,10 @@ class InstanceElement(use_metaclass(cache.CachedMetaClass)): self.is_class_var) new.parent_stmt = par 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): return getattr(self.var, name)