Skip to content

Commit 07aa25d

Browse files
ilevkivskyigvanrossum
authored andcommitted
PEP 484: add an example of iterable unpacking with type comments (#190)
Fixes python/typing#363
1 parent 1f17ac9 commit 07aa25d

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

‎pep-0484.txt‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1367,9 +1367,10 @@ No first-class syntax support for explicitly marking variables as being
13671367
of a specific type is added by this PEP. To help with type inference in
13681368
complex cases, a comment of the following format may be used::
13691369

1370-
x = [] # type: List[Employee]
1370+
x = [] # type: List[Employee]
13711371
x, y, z = [], [], [] # type: List[int], List[int], List[str]
13721372
x, y, z = [], [], [] # type: (List[int], List[int], List[str])
1373+
a, b, *c = range(5) # type: float, float, List[float]
13731374
x = [
13741375
1,
13751376
2,

0 commit comments

Comments
 (0)