fixed minor bug

This commit is contained in:
pca006132 2021-07-09 17:31:54 +08:00
parent e15e29d673
commit 0c8029d7e1
2 changed files with 3 additions and 3 deletions

View File

@ -195,11 +195,11 @@ class TCall(Type):
elif isinstance(x, TFunc):
fn = x
for i in range(len(y.calls)):
if not x.instantiated:
fn = x.instantiate()
posargs, kwargs, ret, _ = y.calls[i]
c = y.calls[i]
c[3] = fn
if not x.instantiated:
fn = x.instantiate()
all_args = set(arg.name for arg in fn.args)
required = set(arg.name for arg in fn.args if not
arg.is_optional)

View File

@ -32,7 +32,7 @@ c = g.foo(True, 1)
d = g.foo(True, True)
f = Foo(1)
g = Foo(1)
g = Foo(True)
"""
print(src)