Refactor the docstring input.
This commit is contained in:
1 parent
fbde21166b
commit
ea1905f121
3 files changed
+9
-8
No files matched your search
@@ -99,9 +99,10 @@ def py__annotations__(funcdef):
|
||||
|
||||
|
||||
@memoize_default()
|
||||
def infer_return_types(context, func):
|
||||
annotation = py__annotations__(func).get("return", None)
|
||||
return _evaluate_for_annotation(context, annotation)
|
||||
def infer_return_types(function_context):
|
||||
annotation = py__annotations__(function_context.tree_node).get("return", None)
|
||||
module_context = function_context.get_root_context()
|
||||
return _evaluate_for_annotation(module_context, annotation)
|
||||
|
||||
|
||||
_typing_module = None
|
||||
|
||||
Reference in new issue
Block a user