Now overloaded functions exist, but the matching doesn't work, yet

This commit is contained in:
Dave Halter committed 2018-08-26 19:39:55 +02:00
1 parent 05d07c23ab
commit 5261cdf4a1
3 files changed
+90 -3

No files matched your search

+2 -1
View File
@@ -296,6 +296,7 @@ class TypeVar(Context):
def execute_annotation(self):
if self._bound_lazy_context is not None:
return self._bound_lazy_context.infer().execute_annotation()
debug.warning('Tried to infer a TypeVar without a given type')
return NO_CONTEXTS
def __repr__(self):
@@ -305,5 +306,5 @@ class TypeVar(Context):
class OverloadFunction(_BaseTypingContext):
@repack_with_argument_clinic('func, /')
def py__call__(self, func_context_set):
debug.warning('overload used %s', func_context_set)
# Just pass arguments through.
return func_context_set