1
0
forked from VimPlug/jedi

Forget to make the set comprehension result a set().

This commit is contained in:
Dave Halter
2015-11-20 15:03:49 +01:00
parent ffaf81bf1b
commit 030131d705
2 changed files with 3 additions and 1 deletions

View File

@@ -341,7 +341,7 @@ class Evaluator(object):
if isinstance(comp_for, tree.CompFor):
if atom.children[0] == '{':
# TODO dict/set comprehensions should be working.
return []
return set()
return set([iterable.Comprehension.from_atom(self, atom)])
return set([iterable.Array(self, atom)])

View File

@@ -124,6 +124,8 @@ right
#?
{a - 1 for a in [1]}
#? int()
{a - 1: 3 for a in [1]}[0]
# -----------------
# name resolution in comprehensions.