1
0
forked from VimPlug/jedi

generators can now be indexed, don't know if this is a good thing. however, it fixes some problems with lists

This commit is contained in:
David Halter
2012-06-27 14:35:12 +02:00
parent 56a14c7811
commit 19a5d788c4
4 changed files with 38 additions and 18 deletions

View File

@@ -661,6 +661,11 @@ class Generator(object):
return self.func.parent
#self.execution.get_return_types()
def get_index_types(self, index):
# TODO check if this method is right here, this means that Generators
# can be indexed, which is not the Python way.
return Execution(self.func).get_return_types(True)
def __repr__(self):
return "<%s of %s>" % (self.__class__.__name__, self.func)