mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2026-09-03 20:52:55 -05:00
Add comment about skipping plain Callable
This commit is contained in:
@@ -315,6 +315,7 @@ def format_annotation(annotation):
|
||||
isinstance(annotation, typing.CallableMeta) and \
|
||||
getattr(annotation, '__args__', None) is not None and \
|
||||
hasattr(annotation, '__result__'):
|
||||
# Skipped in the case of plain typing.Callable
|
||||
args = annotation.__args__
|
||||
if args is Ellipsis:
|
||||
args_str = '...'
|
||||
|
||||
Reference in New Issue
Block a user