summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>2022-03-05 03:21:51 (GMT)
committerGitHub <noreply@github.com>2022-03-05 03:21:51 (GMT)
commit7fba55f15a01742c79214e1abf3e16015eecade8 (patch)
tree64f6e710dccab432ff7f194bb1e38cb6006d42b0
parent01df048831eb631dfee41175f08d09b9ad1a9538 (diff)
downloadcpython-7fba55f15a01742c79214e1abf3e16015eecade8.zip
cpython-7fba55f15a01742c79214e1abf3e16015eecade8.tar.gz
cpython-7fba55f15a01742c79214e1abf3e16015eecade8.tar.bz2
Lib/typing.py copy edits originating from GH-31061 (GH-31684)
(cherry picked from commit 2031149b9a7dfab5f5bad63f417e19f4fc2b9661) Co-authored-by: Matt Bogosian <eb3f73+github+com@yaymail.com>
-rw-r--r--Lib/typing.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/Lib/typing.py b/Lib/typing.py
index af2d8c7..d35a2a5 100644
--- a/Lib/typing.py
+++ b/Lib/typing.py
@@ -285,8 +285,8 @@ def _tp_cache(func=None, /, *, typed=False):
def _eval_type(t, globalns, localns, recursive_guard=frozenset()):
"""Evaluate all forward references in the given type t.
For use of globalns and localns see the docstring for get_type_hints().
- recursive_guard is used to prevent prevent infinite recursion
- with recursive ForwardRef.
+ recursive_guard is used to prevent infinite recursion with a recursive
+ ForwardRef.
"""
if isinstance(t, ForwardRef):
return t._evaluate(globalns, localns, recursive_guard)
@@ -705,7 +705,7 @@ class _BaseGenericAlias(_Final, _root=True):
def __getattr__(self, attr):
# We are careful for copy and pickle.
- # Also for simplicity we just don't relay all dunder names
+ # Also for simplicity we don't relay any dunder names
if '__origin__' in self.__dict__ and not _is_dunder(attr):
return getattr(self.__origin__, attr)
raise AttributeError(attr)