Skip to content

Commit 6c57c32

Browse files
Sync with CPython 3.10 (#137)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
1 parent 43aaebf commit 6c57c32

13 files changed

+2344
-2134
lines changed

c-api/gcsupport.po

Lines changed: 30 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ msgid ""
77
msgstr ""
88
"Project-Id-Version: Python 3.10\n"
99
"Report-Msgid-Bugs-To: \n"
10-
"POT-Creation-Date: 2021-10-26 16:47+0000\n"
10+
"POT-Creation-Date: 2021-10-29 00:08+0000\n"
1111
"PO-Revision-Date: 2018-05-23 14:31+0000\n"
1212
"Last-Translator: Adrian Liaw <adrianliaw2000@gmail.com>\n"
1313
"Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
@@ -64,14 +64,31 @@ msgid ""
6464
"initialized, it must call :c:func:`PyObject_GC_Track`."
6565
msgstr ""
6666

67-
#: ../../c-api/gcsupport.rst:37
67+
#: ../../c-api/gcsupport.rst:36
68+
msgid ""
69+
"Similarly, the deallocator for the object must conform to a similar pair of "
70+
"rules:"
71+
msgstr ""
72+
73+
#: ../../c-api/gcsupport.rst:39
74+
msgid ""
75+
"Before fields which refer to other containers are invalidated, :c:func:"
76+
"`PyObject_GC_UnTrack` must be called."
77+
msgstr ""
78+
79+
#: ../../c-api/gcsupport.rst:42
80+
msgid ""
81+
"The object's memory must be deallocated using :c:func:`PyObject_GC_Del`."
82+
msgstr ""
83+
84+
#: ../../c-api/gcsupport.rst:45
6885
msgid ""
6986
"If a type adds the Py_TPFLAGS_HAVE_GC, then it *must* implement at least a :"
7087
"c:member:`~PyTypeObject.tp_traverse` handler or explicitly use one from its "
7188
"subclass or subclasses."
7289
msgstr ""
7390

74-
#: ../../c-api/gcsupport.rst:41
91+
#: ../../c-api/gcsupport.rst:49
7592
msgid ""
7693
"When calling :c:func:`PyType_Ready` or some of the APIs that indirectly call "
7794
"it like :c:func:`PyType_FromSpecWithBases` or :c:func:`PyType_FromSpec` the "
@@ -82,26 +99,26 @@ msgid ""
8299
"include the :const:`Py_TPFLAGS_HAVE_GC` flag."
83100
msgstr ""
84101

85-
#: ../../c-api/gcsupport.rst:51
102+
#: ../../c-api/gcsupport.rst:59
86103
msgid ""
87104
"Analogous to :c:func:`PyObject_New` but for container objects with the :"
88105
"const:`Py_TPFLAGS_HAVE_GC` flag set."
89106
msgstr ""
90107

91-
#: ../../c-api/gcsupport.rst:57
108+
#: ../../c-api/gcsupport.rst:65
92109
msgid ""
93110
"Analogous to :c:func:`PyObject_NewVar` but for container objects with the :"
94111
"const:`Py_TPFLAGS_HAVE_GC` flag set."
95112
msgstr ""
96113

97-
#: ../../c-api/gcsupport.rst:63
114+
#: ../../c-api/gcsupport.rst:71
98115
msgid ""
99116
"Resize an object allocated by :c:func:`PyObject_NewVar`. Returns the "
100117
"resized object or ``NULL`` on failure. *op* must not be tracked by the "
101118
"collector yet."
102119
msgstr ""
103120

104-
#: ../../c-api/gcsupport.rst:69
121+
#: ../../c-api/gcsupport.rst:77
105122
msgid ""
106123
"Adds the object *op* to the set of container objects tracked by the "
107124
"collector. The collector can run at unexpected times so objects must be "
@@ -110,55 +127,38 @@ msgid ""
110127
"usually near the end of the constructor."
111128
msgstr ""
112129

113-
#: ../../c-api/gcsupport.rst:78
130+
#: ../../c-api/gcsupport.rst:86
114131
msgid ""
115132
"Returns non-zero if the object implements the garbage collector protocol, "
116133
"otherwise returns 0."
117134
msgstr ""
118135

119-
#: ../../c-api/gcsupport.rst:81
136+
#: ../../c-api/gcsupport.rst:89
120137
msgid ""
121138
"The object cannot be tracked by the garbage collector if this function "
122139
"returns 0."
123140
msgstr ""
124141

125-
#: ../../c-api/gcsupport.rst:86
142+
#: ../../c-api/gcsupport.rst:94
126143
msgid ""
127144
"Returns 1 if the object type of *op* implements the GC protocol and *op* is "
128145
"being currently tracked by the garbage collector and 0 otherwise."
129146
msgstr ""
130147

131-
#: ../../c-api/gcsupport.rst:89
148+
#: ../../c-api/gcsupport.rst:97
132149
msgid "This is analogous to the Python function :func:`gc.is_tracked`."
133150
msgstr ""
134151

135-
#: ../../c-api/gcsupport.rst:96
152+
#: ../../c-api/gcsupport.rst:104
136153
msgid ""
137154
"Returns 1 if the object type of *op* implements the GC protocol and *op* has "
138155
"been already finalized by the garbage collector and 0 otherwise."
139156
msgstr ""
140157

141-
#: ../../c-api/gcsupport.rst:99
158+
#: ../../c-api/gcsupport.rst:107
142159
msgid "This is analogous to the Python function :func:`gc.is_finalized`."
143160
msgstr ""
144161

145-
#: ../../c-api/gcsupport.rst:103
146-
msgid ""
147-
"Similarly, the deallocator for the object must conform to a similar pair of "
148-
"rules:"
149-
msgstr ""
150-
151-
#: ../../c-api/gcsupport.rst:106
152-
msgid ""
153-
"Before fields which refer to other containers are invalidated, :c:func:"
154-
"`PyObject_GC_UnTrack` must be called."
155-
msgstr ""
156-
157-
#: ../../c-api/gcsupport.rst:109
158-
msgid ""
159-
"The object's memory must be deallocated using :c:func:`PyObject_GC_Del`."
160-
msgstr ""
161-
162162
#: ../../c-api/gcsupport.rst:114
163163
msgid ""
164164
"Releases memory allocated to an object using :c:func:`PyObject_GC_New` or :c:"

0 commit comments

Comments
 (0)