[Python-checkins] Fix the attribute names in the docstring of GenericAlias (GH-22594)

Mikhail Golubev webhook-mailer at python.org
Thu Oct 8 17:38:49 EDT 2020


https://github.com/python/cpython/commit/77f0a23e7a9fb247101b9b14a060c4ba1c4b87a5
commit: 77f0a23e7a9fb247101b9b14a060c4ba1c4b87a5
branch: master
author: Mikhail Golubev <qsolo825 at gmail.com>
committer: GitHub <noreply at github.com>
date: 2020-10-08T14:38:36-07:00
summary:

Fix the attribute names in the docstring of GenericAlias (GH-22594)

files:
M Objects/genericaliasobject.c

diff --git a/Objects/genericaliasobject.c b/Objects/genericaliasobject.c
index ab56e1c4bf1a8..6508c69cbf7e3 100644
--- a/Objects/genericaliasobject.c
+++ b/Objects/genericaliasobject.c
@@ -582,7 +582,7 @@ PyTypeObject Py_GenericAliasType = {
     .tp_name = "types.GenericAlias",
     .tp_doc = "Represent a PEP 585 generic type\n"
               "\n"
-              "E.g. for t = list[int], t.origin is list and t.args is (int,).",
+              "E.g. for t = list[int], t.__origin__ is list and t.__args__ is (int,).",
     .tp_basicsize = sizeof(gaobject),
     .tp_dealloc = ga_dealloc,
     .tp_repr = ga_repr,



More information about the Python-checkins mailing list