8000 fastparse: fix type checking on 3.8 (#9693) · python/mypy@ff2ae7c · GitHub
[go: up one dir, main page]

Skip to content
8000

Commit ff2ae7c

Browse files
authored
fastparse: fix type checking on 3.8 (#9693)
This got broken by python/typeshed#4740 It took me a little bit to figure out how this evaded all our CI, but it's because we type check with version 3.5 and mypyc only with 3.5 and 3.7. That is, we do not type check with 3.8 or later and so do not check against stdlib's AST types. mypyc wheels did break through, but I'm not sure anyone gets to see those. Maybe we should add a badge for them to the README. I only noticed this because I was trying to get mypy_primer to mypyc compile sometimes. Co-authored-by: hauntsaninja <>
1 parent 52702e5 commit ff2ae7c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

mypy/fastparse.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -676,11 +676,11 @@ def transform_args(self,
676676
names.append(args.vararg)
677677

678678
# keyword-only arguments with defaults
679-
for a, d in zip(args.kwonlyargs, args.kw_defaults):
679+
for a, kd in zip(args.kwonlyargs, args.kw_defaults):
680680
new_args.append(self.make_argument(
681681
a,
682-
d,
683-
ARG_NAMED if d is None else ARG_NAMED_OPT,
682+
kd,
683+
ARG_NAMED if kd is None else ARG_NAMED_OPT,
684684
no_type_check))
685685
names.append(a)
686686

0 commit comments

Comments
 (0)
0