Fix a typo in docs for typing.Concatenate (#24169)

Return param spec should be R, not T
This commit is contained in:
Johan Dahlin 2021-01-08 15:08:21 -03:00 committed by GitHub
parent 11ef53aefb
commit 68e1f259be
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -707,7 +707,7 @@ These can be used as types in annotations using ``[]``, each having a unique syn
def with_lock(f: Callable[Concatenate[Lock, P], R]) -> Callable[P, R]:
'''A type-safe decorator which provides a lock.'''
global my_lock
def inner(*args: P.args, **kwargs: P.kwargs) -> T:
def inner(*args: P.args, **kwargs: P.kwargs) -> R:
# Provide the lock as the first argument.
return f(my_lock, *args, **kwargs)
return inner