mirror of
https://github.com/davidhalter/jedi.git
synced 2025-12-06 22:14:27 +08:00
Add an exact_key_items method to DictComprehension fixes #1233
This commit is contained in:
committed by
Dave Halter
parent
bd1010bbd2
commit
3bdb941daa
@@ -138,18 +138,30 @@ set_t2.c
|
||||
# python >= 3.5
|
||||
|
||||
d = {'a': 3}
|
||||
dc = {v: 3 for v in ['a']}
|
||||
|
||||
#? dict()
|
||||
{**d}
|
||||
|
||||
#? dict()
|
||||
{**dc}
|
||||
|
||||
#? str()
|
||||
{**d, "b": "b"}["b"]
|
||||
|
||||
#? str()
|
||||
{**dc, "b": "b"}["b"]
|
||||
|
||||
# Should resolve to int() but jedi is not smart enough yet
|
||||
# Here to make sure it doesn't result in crash though
|
||||
#?
|
||||
{**d}["a"]
|
||||
|
||||
# Should resolve to int() but jedi is not smart enough yet
|
||||
# Here to make sure it doesn't result in crash though
|
||||
#?
|
||||
{**dc}["a"]
|
||||
|
||||
s = {1, 2, 3}
|
||||
|
||||
#? set()
|
||||
|
||||
Reference in New Issue
Block a user