66# Translators:
77# Shengjing Zhu <[email protected] >, 201988# Trim21 <[email protected] >, 20199- 109# Freesand Leo <[email protected] >, 20201110#
1211#, fuzzy
1312msgid ""
1413msgstr ""
1514"Project-Id-Version : Python 3.9\n "
1615"Report-Msgid-Bugs-To : \n "
17- "POT-Creation-Date : 2021-01-01 05:02 +0000\n "
16+ "POT-Creation-Date : 2021-01-07 05:06 +0000\n "
1817"PO-Revision-Date : 2017-02-16 17:33+0000\n "
1918"
Last-Translator :
Freesand Leo <[email protected] >, 2020\n "
2019"Language-Team : Chinese (China) (https://www.transifex.com/python-doc/teams/5390/zh_CN/)\n "
@@ -57,20 +56,22 @@ msgid ""
5756msgstr "参阅 :c:func:`PyCapsule_New` 来获取 PyCapsule_Destructor 返回值的语义。"
5857
5958#: ../../c-api/capsule.rst:37
60- msgid "Return true if its argument is a :c:type:`PyCapsule`."
61- msgstr "如果参数是一个 :c:type:`PyCapsule` 则返回 True"
59+ msgid ""
60+ "Return true if its argument is a :c:type:`PyCapsule`. This function always "
61+ "succeeds."
62+ msgstr ""
6263
63- #: ../../c-api/capsule.rst:42
64+ #: ../../c-api/capsule.rst:43
6465msgid ""
6566"Create a :c:type:`PyCapsule` encapsulating the *pointer*. The *pointer* "
6667"argument may not be ``NULL``."
6768msgstr "创建一个封装了 *pointer* 的 :c:type:`PyCapsule`。 *pointer* 参考可以不为 ``NULL``。"
6869
69- #: ../../c-api/capsule.rst:45
70+ #: ../../c-api/capsule.rst:46
7071msgid "On failure, set an exception and return ``NULL``."
7172msgstr "在失败时设置一个异常并返回 ``NULL``。"
7273
73- #: ../../c-api/capsule.rst:47
74+ #: ../../c-api/capsule.rst:48
7475msgid ""
7576"The *name* string may either be ``NULL`` or a pointer to a valid C string. "
7677"If non-``NULL``, this string must outlive the capsule. (Though it is "
@@ -79,13 +80,13 @@ msgstr ""
7980"字符串 *name* 可以是 ``NULL`` 或是一个指向有效的 C 字符串的指针。 如果不为 ``NULL``,则此字符串必须比 capsule "
8081"长(虽然也允许在 *destructor* 中释放它。)"
8182
82- #: ../../c-api/capsule.rst:51
83+ #: ../../c-api/capsule.rst:52
8384msgid ""
8485"If the *destructor* argument is not ``NULL``, it will be called with the "
8586"capsule as its argument when it is destroyed."
8687msgstr "如果 *destructor* 参数不为 ``NULL``,则当它被销毁时将附带 capsule 作为参数来调用。"
8788
88- #: ../../c-api/capsule.rst:54
89+ #: ../../c-api/capsule.rst:55
8990msgid ""
9091"If this capsule will be stored as an attribute of a module, the *name* "
9192"should be specified as ``modulename.attributename``. This will enable other"
@@ -94,13 +95,13 @@ msgstr ""
9495"如果此 capsule 将被保存为一个模块的属性,则 *name* 应当被指定为 ``modulename.attributename``。 "
9596"这将允许其他模块使用 :c:func:`PyCapsule_Import` 来导入此 capsule。"
9697
97- #: ../../c-api/capsule.rst:61
98+ #: ../../c-api/capsule.rst:62
9899msgid ""
99100"Retrieve the *pointer* stored in the capsule. On failure, set an exception "
100101"and return ``NULL``."
101102msgstr "提取保存在 capsule 中的 *pointer*。 在失败时设置一个异常并返回 ``NULL``。"
102103
103- #: ../../c-api/capsule.rst:64
104+ #: ../../c-api/capsule.rst:65
104105msgid ""
105106"The *name* parameter must compare exactly to the name stored in the capsule."
106107" If the name stored in the capsule is ``NULL``, the *name* passed in must "
@@ -110,13 +111,13 @@ msgstr ""
110111"*name* 形参必须与保存在 capsule 中的名称进行精确比较。 如果保存在 capsule 中的名称为 ``NULL``,则传入的 *name*"
111112" 也必须为 ``NULL``。 Python 会使用 C 函数 :c:func:`strcmp` 来比较 capsule 名称。"
112113
113- #: ../../c-api/capsule.rst:72
114+ #: ../../c-api/capsule.rst:73
114115msgid ""
115116"Return the current destructor stored in the capsule. On failure, set an "
116117"exception and return ``NULL``."
117118msgstr "返回保存在 capsule 中的当前析构器。 在失败时设置一个异常并返回 ``NULL``。"
118119
119- #: ../../c-api/capsule.rst:75
120+ #: ../../c-api/capsule.rst:76
120121msgid ""
121122"It is legal for a capsule to have a ``NULL`` destructor. This makes a "
122123"``NULL`` return code somewhat ambiguous; use :c:func:`PyCapsule_IsValid` or "
@@ -125,13 +126,13 @@ msgstr ""
125126"capsule 具有 ``NULL`` 析构器是合法的。 这会使得 ``NULL`` 返回码有些歧义;请使用 "
126127":c:func:`PyCapsule_IsValid` 或 :c:func:`PyErr_Occurred` 来消除歧义。"
127128
128- #: ../../c-api/capsule.rst:82
129+ #: ../../c-api/capsule.rst:83
129130msgid ""
130131"Return the current context stored in the capsule. On failure, set an "
131132"exception and return ``NULL``."
132133msgstr "返回保存在 capsule 中的当前上下文。 在失败时设置一个异常并返回 ``NULL``。"
133134
134- #: ../../c-api/capsule.rst:85
135+ #: ../../c-api/capsule.rst:86
135136msgid ""
136137"It is legal for a capsule to have a ``NULL`` context. This makes a ``NULL``"
137138" return code somewhat ambiguous; use :c:func:`PyCapsule_IsValid` or "
@@ -140,13 +141,13 @@ msgstr ""
140141"capsule 具有 ``NULL`` 上下文是全法的。 这会使得 ``NULL`` 返回码有些歧义;请使用 "
141142":c:func:`PyCapsule_IsValid` 或 :c:func:`PyErr_Occurred` 来消除歧义。"
142143
143- #: ../../c-api/capsule.rst:92
144+ #: ../../c-api/capsule.rst:93
144145msgid ""
145146"Return the current name stored in the capsule. On failure, set an exception"
146147" and return ``NULL``."
147148msgstr "返回保存在 capsule 中的当前名称。 在失败时设置一个异常并返回 ``NULL``。"
148149
149- #: ../../c-api/capsule.rst:95
150+ #: ../../c-api/capsule.rst:96
150151msgid ""
151152"It is legal for a capsule to have a ``NULL`` name. This makes a ``NULL`` "
152153"return code somewhat ambiguous; use :c:func:`PyCapsule_IsValid` or "
@@ -155,7 +156,7 @@ msgstr ""
155156"capsule 具有 ``NULL`` 名称是合法的。 这会使得 ``NULL`` 返回码有些歧义;请使用 "
156157":c:func:`PyCapsule_IsValid` 或 :c:func:`PyErr_Occurred` 来消除歧义。"
157158
158- #: ../../c-api/capsule.rst:102
159+ #: ../../c-api/capsule.rst:103
159160msgid ""
160161"Import a pointer to a C object from a capsule attribute in a module. The "
161162"*name* parameter should specify the full name to the attribute, as in "
@@ -169,13 +170,13 @@ msgstr ""
169170":c:func:`PyImport_ImportModuleNoBlock`)。 如果 *no_block* 为假值,则以传统模式导入模块 (使用 "
170171":c:func:`PyImport_ImportModule`)。"
171172
172- #: ../../c-api/capsule.rst:109
173+ #: ../../c-api/capsule.rst:110
173174msgid ""
174175"Return the capsule's internal *pointer* on success. On failure, set an "
175176"exception and return ``NULL``."
176177msgstr "成功时返回 capsule 的内部 *指针*。 在失败时设置一个异常并返回 ``NULL``。"
177178
178- #: ../../c-api/capsule.rst:115
179+ #: ../../c-api/capsule.rst:116
179180msgid ""
180181"Determines whether or not *capsule* is a valid capsule. A valid capsule is "
181182"non-``NULL``, passes :c:func:`PyCapsule_CheckExact`, has a non-``NULL`` "
@@ -187,7 +188,7 @@ msgstr ""
187188":c:func:`PyCapsule_CheckExact`,在其中存储一个不为 ``NULL`` 的指针,并且其内部名称与 *name* 形参相匹配。"
188189" (请参阅 :c:func:`PyCapsule_GetPointer` 了解如何对 capsule 名称进行比较的有关信息。)"
189190
190- #: ../../c-api/capsule.rst:121
191+ #: ../../c-api/capsule.rst:122
191192msgid ""
192193"In other words, if :c:func:`PyCapsule_IsValid` returns a true value, calls "
193194"to any of the accessors (any function starting with :c:func:`PyCapsule_Get`)"
@@ -196,27 +197,27 @@ msgstr ""
196197"换句话说,如果 :c:func:`PyCapsule_IsValid` 返回真值,则任何对访问器(以 :c:func:`PyCapsule_Get` "
197198"开头的任何函数)的调用都保证会成功。"
198199
199- #: ../../c-api/capsule.rst:125
200+ #: ../../c-api/capsule.rst:126
200201msgid ""
201202"Return a nonzero value if the object is valid and matches the name passed "
202203"in. Return ``0`` otherwise. This function will not fail."
203204msgstr "如果对象有效并且匹配传入的名称则返回非零值。 否则返回 ``0``。 此函数一定不会失败。"
204205
205- #: ../../c-api/capsule.rst:131
206+ #: ../../c-api/capsule.rst:132
206207msgid "Set the context pointer inside *capsule* to *context*."
207208msgstr "将 *capsule* 内部的上下文指针设为 *context*。"
208209
209- #: ../../c-api/capsule.rst:133 ../../c-api/capsule.rst:140
210- #: ../../c-api/capsule.rst:149 ../../c-api/capsule.rst:157
210+ #: ../../c-api/capsule.rst:134 ../../c-api/capsule.rst:141
211+ #: ../../c-api/capsule.rst:150 ../../c-api/capsule.rst:158
211212msgid ""
212213"Return ``0`` on success. Return nonzero and set an exception on failure."
213214msgstr "成功时返回 ``0``。 失败时返回非零值并设置一个异常。"
214215
215- #: ../../c-api/capsule.rst:138
216+ #: ../../c-api/capsule.rst:139
216217msgid "Set the destructor inside *capsule* to *destructor*."
217218msgstr "将 *capsule* 内部的析构器设为 *destructor*。"
218219
219- #: ../../c-api/capsule.rst:145
220+ #: ../../c-api/capsule.rst:146
220221msgid ""
221222"Set the name inside *capsule* to *name*. If non-``NULL``, the name must "
222223"outlive the capsule. If the previous *name* stored in the capsule was not "
@@ -225,7 +226,7 @@ msgstr ""
225226"将 *capsule* 内部的名称设为 *name*。 如果不为 ``NULL``,则名称的存在期必须比 capsule 更长。 如果之前保存在 "
226227"capsule 中的 *name* 不为 ``NULL``,则不会尝试释放它。"
227228
228- #: ../../c-api/capsule.rst:154
229+ #: ../../c-api/capsule.rst:155
229230msgid ""
230231"Set the void pointer inside *capsule* to *pointer*. The pointer may not be "
231232"``NULL``."
0 commit comments