File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -318,8 +318,10 @@ def _resolved_function_signature(
318318 sig = sig .replace (
319319 parameters = params , return_annotation = return_annotation
320320 )
321+ return sig
321322
322- return sig
323+ else :
324+ return None
323325
324326
325327def get_local_defns (
@@ -359,26 +361,15 @@ def get_local_defns(
359361 # TODO: This annos_ok thing is a hack because processing
360362 # __annotations__ on methods broke stuff and I didn't want
361363 # to chase it down yet.
362- stuck = False
363- try :
364- rr = get_annotations (
365- stuff , boxed .str_args , cls = boxed .cls , annos_ok = False
366- )
367- except _eval_typing .StuckException :
368- stuck = True
369- rr = None
370-
371364 resolved_sig = None
372- if rr is not None :
373- resolved_sig = _resolved_function_signature (
374- stuff , boxed .str_args , definition_cls = boxed .cls
375- )
376- elif not stuck and getattr (stuff , "__annotations__" , None ):
377- # XXX: This is totally wrong; we still need to do
378- # substitute in class vars
365+ try :
379366 resolved_sig = _resolved_function_signature (
380- stuff , boxed .str_args , definition_cls = boxed .cls
367+ stuff ,
368+ boxed .str_args ,
369+ definition_cls = boxed .cls ,
381370 )
371+ except _eval_typing .StuckException :
372+ pass
382373 overloads = typing .get_overloads (stuff )
383374
384375 # If the method has type params, we build a GenericCallable
You can’t perform that action at this time.
0 commit comments