From 43188f958c13673f8b3928164e9164b6fd48fa87 Mon Sep 17 00:00:00 2001 From: Johan Dahlin Date: Fri, 8 Jan 2021 14:41:25 -0300 Subject: [PATCH] Fix a typo Return param spec should be R, not T --- Doc/library/typing.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/library/typing.rst b/Doc/library/typing.rst index d74f8bcc27a20a..c14c7108133819 100644 --- a/Doc/library/typing.rst +++ b/Doc/library/typing.rst @@ -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