Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit5ae6973

Browse files
[po] auto sync
1 parent2db1586 commit5ae6973

File tree

12 files changed

+14045
-13875
lines changed

12 files changed

+14045
-13875
lines changed

‎.stat.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{"translation":"99.79%","updated_at":"2025-11-07T06:59:28Z"}
1+
{"translation":"99.75%","updated_at":"2025-11-07T15:57:51Z"}

‎c-api/dict.po‎

Lines changed: 28 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ msgid ""
1212
msgstr ""
1313
"Project-Id-Version:Python 3.13\n"
1414
"Report-Msgid-Bugs-To:\n"
15-
"POT-Creation-Date:2025-11-03 15:10+0000\n"
15+
"POT-Creation-Date:2025-11-07 15:30+0000\n"
1616
"PO-Revision-Date:2025-09-15 01:03+0000\n"
1717
"Last-Translator:Freesand Leo <yuqinju@163.com>, 2025\n"
1818
"Language-Team:Chinese (China) (https://app.transifex.com/python-doc/teams/5390/zh_CN/)\n"
@@ -311,6 +311,10 @@ msgid ""
311311
msgstr"返回字典中项目数,等价于对字典 *p* 使用 ``len(p)``。"
312312

313313
#:../../c-api/dict.rst:250
314+
msgid"Similar to :c:func:`PyDict_Size`, but without error checking."
315+
msgstr"类似于 :c:func:`PyDict_Size`,但是不带错误检查。"
316+
317+
#:../../c-api/dict.rst:255
314318
msgid""
315319
"Iterate over all key-value pairs in the dictionary *p*. The "
316320
":c:type:`Py_ssize_t` referred to by *ppos* must be initialized to ``0`` "
@@ -328,11 +332,11 @@ msgstr ""
328332
":c:expr:`PyObject*` 变量,它们将分别使用每个键和值来填充,或者也可以为 ``NULL``。 通过它们返回的任何引用都是暂借的。 "
329333
"*ppos* 在迭代期间不应被更改。 它的值表示内部字典结构中的偏移量,并且由于结构是稀疏的,因此偏移量并不连续。"
330334

331-
#:../../c-api/dict.rst:261
335+
#:../../c-api/dict.rst:266
332336
msgid"For example::"
333337
msgstr"例如:"
334338

335-
#:../../c-api/dict.rst:263
339+
#:../../c-api/dict.rst:268
336340
msgid""
337341
"PyObject *key, *value;\n"
338342
"Py_ssize_t pos = 0;\n"
@@ -350,14 +354,14 @@ msgstr ""
350354
" ...\n"
351355
"}"
352356

353-
#:../../c-api/dict.rst:271
357+
#:../../c-api/dict.rst:276
354358
msgid""
355359
"The dictionary *p* should not be mutated during iteration. It is safe to "
356360
"modify the values of the keys as you iterate over the dictionary, but only "
357361
"so long as the set of keys does not change. For example::"
358362
msgstr"字典 *p* 不应该在遍历期间发生改变。在遍历字典时,改变键中的值是安全的,但仅限于键的集合不发生改变。例如::"
359363

360-
#:../../c-api/dict.rst:275
364+
#:../../c-api/dict.rst:280
361365
msgid""
362366
"PyObject *key, *value;\n"
363367
"Py_ssize_t pos = 0;\n"
@@ -395,7 +399,7 @@ msgstr ""
395399
" Py_DECREF(o);\n"
396400
"}"
397401

398-
#:../../c-api/dict.rst:293
402+
#:../../c-api/dict.rst:298
399403
msgid""
400404
"The function is not thread-safe in the :term:`free-threaded <free "
401405
"threading>` build without external synchronization. You can use "
@@ -405,7 +409,7 @@ msgstr ""
405409
"此函数在没有外部同步的 :term:`自由线程 <free threading>` 编译版中不是线程安全的。 你可以使用 "
406410
":c:macro:`Py_BEGIN_CRITICAL_SECTION` 在迭代字典时锁定它::"
407411

408-
#:../../c-api/dict.rst:298
412+
#:../../c-api/dict.rst:303
409413
msgid""
410414
"Py_BEGIN_CRITICAL_SECTION(self->dict);\n"
411415
"while (PyDict_Next(self->dict, &pos, &key, &value)) {\n"
@@ -419,7 +423,7 @@ msgstr ""
419423
"}\n"
420424
"Py_END_CRITICAL_SECTION();"
421425

422-
#:../../c-api/dict.rst:307
426+
#:../../c-api/dict.rst:312
423427
msgid""
424428
"Iterate over mapping object *b* adding key-value pairs to dictionary *a*. "
425429
"*b* may be a dictionary, or any object supporting :c:func:`PyMapping_Keys` "
@@ -432,7 +436,7 @@ msgstr ""
432436
":c:func:`PyObject_GetItem` 的对象。 如果 *override* 为真值,则如果在 *b* 中找到相同的键则 *a* "
433437
"中已存在的相应键值对将被替换,否则如果在 *a* 中没有相同的键则只是添加键值对。 当成功时返回 ``0`` 或者当引发异常时返回 ``-1``。"
434438

435-
#:../../c-api/dict.rst:317
439+
#:../../c-api/dict.rst:322
436440
msgid""
437441
"This is the same as ``PyDict_Merge(a, b, 1)`` in C, and is similar to "
438442
"``a.update(b)`` in Python except that :c:func:`PyDict_Update` doesn't fall "
@@ -444,7 +448,7 @@ msgstr ""
444448
":c:func:`PyDict_Update` 在第二个参数没有\"keys\" 属性时不会回退到迭代键值对的序列。 当成功时返回 ``0`` "
445449
"或者当引发异常时返回 ``-1``。"
446450

447-
#:../../c-api/dict.rst:326
451+
#:../../c-api/dict.rst:331
448452
msgid""
449453
"Update or merge into dictionary *a*, from the key-value pairs in *seq2*. "
450454
"*seq2* must be an iterable object producing iterable objects of length 2, "
@@ -457,7 +461,7 @@ msgstr ""
457461
"*override* 真值则最后出现的键胜出。 当成功时返回 ``0`` 或者当引发异常时返回 ``-1``。 等价的 Python "
458462
"代码(返回值除外)::"
459463

460-
#:../../c-api/dict.rst:333
464+
#:../../c-api/dict.rst:338
461465
msgid""
462466
"def PyDict_MergeFromSeq2(a, seq2, override):\n"
463467
" for key, value in seq2:\n"
@@ -469,7 +473,7 @@ msgstr ""
469473
" if override or key not in a:\n"
470474
" a[key] = value"
471475

472-
#:../../c-api/dict.rst:340
476+
#:../../c-api/dict.rst:345
473477
msgid""
474478
"Register *callback* as a dictionary watcher. Return a non-negative integer "
475479
"id which must be passed to future calls to :c:func:`PyDict_Watch`. In case "
@@ -479,7 +483,7 @@ msgstr ""
479483
"在字典上注册 *callback* 来作为 watcher。返回值为非负数的整数 id,作为将来调用 :c:func:`PyDict_Watch` "
480484
"的时候使用。如果出现错误(比如没有足够的可用 watcher ID),返回 ``-1`` 并且设置异常。"
481485

482-
#:../../c-api/dict.rst:349
486+
#:../../c-api/dict.rst:354
483487
msgid""
484488
"Clear watcher identified by *watcher_id* previously returned from "
485489
":c:func:`PyDict_AddWatcher`. Return ``0`` on success, ``-1`` on error (e.g. "
@@ -488,7 +492,7 @@ msgstr ""
488492
"清空由之前从 :c:func:`PyDict_AddWatcher` 返回的 *watcher_id* 所标识的 watcher。 成功时返回 "
489493
"``0``,出错时(例如当给定的 *watcher_id* 未被注册)返回 ``-1``。"
490494

491-
#:../../c-api/dict.rst:357
495+
#:../../c-api/dict.rst:362
492496
msgid""
493497
"Mark dictionary *dict* as watched. The callback granted *watcher_id* by "
494498
":c:func:`PyDict_AddWatcher` will be called when *dict* is modified or "
@@ -497,7 +501,7 @@ msgstr ""
497501
"将字典 *dict* 标记为已被监视。 由 :c:func:`PyDict_AddWatcher` 授权 *watcher_id* 对应的回调将在 "
498502
"*dict* 被修改或释放时被调用。 成功时返回 ``0``,出错时返回 ``-1``。"
499503

500-
#:../../c-api/dict.rst:365
504+
#:../../c-api/dict.rst:370
501505
msgid""
502506
"Mark dictionary *dict* as no longer watched. The callback granted "
503507
"*watcher_id* by :c:func:`PyDict_AddWatcher` will no longer be called when "
@@ -507,7 +511,7 @@ msgstr ""
507511
"将字典 *dict* 标记为不再被监视。 由 :c:func:`PyDict_AddWatcher` 授权 *watcher_id* 对应的回调在 "
508512
"*dict* 被修改或释放时将不再被调用。 该字典在此之前必须已被此监视器所监视。 成功时返回 ``0``,出错时返回 ``-1``。"
509513

510-
#:../../c-api/dict.rst:374
514+
#:../../c-api/dict.rst:379
511515
msgid""
512516
"Enumeration of possible dictionary watcher events: ``PyDict_EVENT_ADDED``, "
513517
"``PyDict_EVENT_MODIFIED``, ``PyDict_EVENT_DELETED``, "
@@ -518,11 +522,11 @@ msgstr ""
518522
"``PyDict_EVENT_DELETED``, ``PyDict_EVENT_CLONED``, ``PyDict_EVENT_CLEARED`` "
519523
"或 ``PyDict_EVENT_DEALLOCATED``。"
520524

521-
#:../../c-api/dict.rst:382
525+
#:../../c-api/dict.rst:387
522526
msgid"Type of a dict watcher callback function."
523527
msgstr"字典监视器回调函数的类型。"
524528

525-
#:../../c-api/dict.rst:384
529+
#:../../c-api/dict.rst:389
526530
msgid""
527531
"If *event* is ``PyDict_EVENT_CLEARED`` or ``PyDict_EVENT_DEALLOCATED``, both"
528532
" *key* and *new_value* will be ``NULL``. If *event* is "
@@ -535,7 +539,7 @@ msgstr ""
535539
"``PyDict_EVENT_MODIFIED``,则 *new_value* 将为 *key* 的新值。 如果 *event* 是 "
536540
"``PyDict_EVENT_DELETED``,则将从字典中删除 *key* 而 *new_value* 将为 ``NULL``。"
537541

538-
#:../../c-api/dict.rst:390
542+
#:../../c-api/dict.rst:395
539543
msgid""
540544
"``PyDict_EVENT_CLONED`` occurs when *dict* was previously empty and another "
541545
"dict is merged into it. To maintain efficiency of this operation, per-key "
@@ -545,7 +549,7 @@ msgstr ""
545549
"``PyDict_EVENT_CLONED`` 会在另一个字典合并到之前为空的 *dict* 时发生。 为保证此操作的效率,该场景不会发出针对单个键的 "
546550
"``PyDict_EVENT_ADDED`` 事件;而是发出单个 ``PyDict_EVENT_CLONED``,而 *key* 将为源字典。"
547551

548-
#:../../c-api/dict.rst:396
552+
#:../../c-api/dict.rst:401
549553
msgid""
550554
"The callback may inspect but must not modify *dict*; doing so could have "
551555
"unpredictable effects, including infinite recursion. Do not trigger Python "
@@ -555,7 +559,7 @@ msgstr ""
555559
"该回调可以检查但不能修改 *dict*;否则会产生不可预料的影响,包括无限递归。 请不要在该回调中触发 Python 代码的执行,因为它可能产生修改 "
556560
"dict 的附带影响。"
557561

558-
#:../../c-api/dict.rst:400
562+
#:../../c-api/dict.rst:405
559563
msgid""
560564
"If *event* is ``PyDict_EVENT_DEALLOCATED``, taking a new reference in the "
561565
"callback to the about-to-be-destroyed dictionary will resurrect it and "
@@ -567,13 +571,13 @@ msgstr ""
567571
"``PyDict_EVENT_DEALLOCATED``,则在回调中接受一个对即将销毁的字典的新引用将使其重生并阻止其在此时被释放。 "
568572
"当重生的对象以后再被销毁时,任何在当时已激活的监视器回调将再次被调用。"
569573

570-
#:../../c-api/dict.rst:406
574+
#:../../c-api/dict.rst:411
571575
msgid""
572576
"Callbacks occur before the notified modification to *dict* takes place, so "
573577
"the prior state of *dict* can be inspected."
574578
msgstr"回调会在已通知的对 *dict* 的修改完成之前执行,这样在此之前的 *dict* 状态可以被检查。"
575579

576-
#:../../c-api/dict.rst:409
580+
#:../../c-api/dict.rst:414
577581
msgid""
578582
"If the callback sets an exception, it must return ``-1``; this exception "
579583
"will be printed as an unraisable exception using "
@@ -582,7 +586,7 @@ msgstr ""
582586
"如果该回调设置了一个异常,则它必须返回 ``-1``;此异常将作为不可引发的异常使用 :c:func:`PyErr_WriteUnraisable` "
583587
"打印出来。 在其他情况下它应当返回 ``0``。"
584588

585-
#:../../c-api/dict.rst:413
589+
#:../../c-api/dict.rst:418
586590
msgid""
587591
"There may already be a pending exception set on entry to the callback. In "
588592
"this case, the callback should return ``0`` with the same exception still "

‎c-api/float.po‎

Lines changed: 46 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,16 @@
55
#
66
# Translators:
77
# python-doc bot, 2025
8+
# Freesand Leo <yuqinju@163.com>, 2025
89
#
910
#,fuzzy
1011
msgid ""
1112
msgstr ""
1213
"Project-Id-Version:Python 3.13\n"
1314
"Report-Msgid-Bugs-To:\n"
14-
"POT-Creation-Date:2025-01-03 14:16+0000\n"
15+
"POT-Creation-Date:2025-11-07 15:30+0000\n"
1516
"PO-Revision-Date:2025-09-15 01:03+0000\n"
16-
"Last-Translator:python-doc bot, 2025\n"
17+
"Last-Translator:Freesand Leo <yuqinju@163.com>, 2025\n"
1718
"Language-Team:Chinese (China) (https://app.transifex.com/python-doc/teams/5390/zh_CN/)\n"
1819
"MIME-Version:1.0\n"
1920
"Content-Type:text/plain; charset=UTF-8\n"
@@ -111,11 +112,34 @@ msgid ""
111112
":c:expr:`double`."
112113
msgstr"返回 C :c:expr:`double` 形式的最小正规化正浮点数 *DBL_MIN*。"
113114

114-
#:../../c-api/float.rst:82
115+
#:../../c-api/float.rst:83
116+
msgid"Return :data:`math.nan` from a function."
117+
msgstr"从一个函数返回 :data:`math.nan`。"
118+
119+
#:../../c-api/float.rst:85
120+
msgid""
121+
"On most platforms, this is equivalent to ``return PyFloat_FromDouble(NAN)``."
122+
msgstr""
123+
124+
#:../../c-api/float.rst:90
125+
msgid""
126+
"Return :data:`math.inf` or :data:`-math.inf <math.inf>` from a function, "
127+
"depending on the sign of *sign*."
128+
msgstr""
129+
130+
#:../../c-api/float.rst:93
131+
msgid"On most platforms, this is equivalent to the following::"
132+
msgstr""
133+
134+
#:../../c-api/float.rst:95
135+
msgid"return PyFloat_FromDouble(copysign(INFINITY, sign));"
136+
msgstr""
137+
138+
#:../../c-api/float.rst:99
115139
msgid"Pack and Unpack functions"
116140
msgstr"打包与解包函数"
117141

118-
#:../../c-api/float.rst:84
142+
#:../../c-api/float.rst:101
119143
msgid""
120144
"The pack and unpack functions provide an efficient platform-independent way "
121145
"to store floating-point values as byte strings. The Pack routines produce a "
@@ -126,7 +150,7 @@ msgstr ""
126150
"打包与解包函数提供了独立于平台的高效方式来将浮点数值存储为字节串。 Pack 例程根据 C :c:expr:`double` 产生字节串,而 "
127151
"Unpack 例程根据这样的字节串产生 C :c:expr:`double`。 后缀 (2, 4 or 8) 指明字节串中的字节数。"
128152

129-
#:../../c-api/float.rst:90
153+
#:../../c-api/float.rst:107
130154
msgid""
131155
"On platforms that appear to use IEEE 754 formats these functions work by "
132156
"copying bits. On other platforms, the 2-byte format is identical to the IEEE"
@@ -142,7 +166,7 @@ msgstr ""
142166
"双精度格式相同,不过 INF 和 NaN (如果平台存在这两种值) 未得到正确处理,而试图对包含 IEEE INF 或 NaN "
143167
"的字节串执行解包将会引发一个异常。"
144168

145-
#:../../c-api/float.rst:99
169+
#:../../c-api/float.rst:116
146170
msgid""
147171
"On non-IEEE platforms with more precision, or larger dynamic range, than "
148172
"IEEE 754 supports, not all values can be packed; on non-IEEE platforms with "
@@ -152,11 +176,11 @@ msgstr ""
152176
"在具有比 IEEE 754 所支持的更高精度,或更大动态范围的非 IEEE 平台上,不是所有的值都能被打包;在具有更低精度,或更小动态范围的非 IEEE"
153177
" 平台上,则不是所有的值都能被解包。 在这种情况下发生的事情有一部分将是偶然的(无奈)。"
154178

155-
#:../../c-api/float.rst:107
179+
#:../../c-api/float.rst:124
156180
msgid"Pack functions"
157181
msgstr"打包函数"
158182

159-
#:../../c-api/float.rst:109
183+
#:../../c-api/float.rst:126
160184
msgid""
161185
"The pack routines write 2, 4 or 8 bytes, starting at *p*. *le* is an "
162186
":c:expr:`int` argument, non-zero if you want the bytes string in little-"
@@ -171,42 +195,42 @@ msgstr ""
171195
"(指数部分放在前面,位于 *p*) 则其应为零。 :c:macro:`PY_BIG_ENDIAN` 常量可被用于使用本机端序:在大端序处理器上等于 "
172196
"``1``,在小端序处理器上则等于 ``0``。"
173197

174-
#:../../c-api/float.rst:116
198+
#:../../c-api/float.rst:133
175199
msgid""
176200
"Return value: ``0`` if all is OK, ``-1`` if error (and an exception is set, "
177201
"most likely :exc:`OverflowError`)."
178202
msgstr""
179203
"返回值: 如果一切正常则为 ``0``,如果出错则为 ``-1`` (并会设置一个异常,最大可能为 :exc:`OverflowError`)。"
180204

181-
#:../../c-api/float.rst:119
205+
#:../../c-api/float.rst:136
182206
msgid"There are two problems on non-IEEE platforms:"
183207
msgstr"在非 IEEE 平台上存在两个问题:"
184208

185-
#:../../c-api/float.rst:121
209+
#:../../c-api/float.rst:138
186210
msgid"What this does is undefined if *x* is a NaN or infinity."
187211
msgstr"如果 *x* 为 NaN 或无穷大则此函数的行为是未定义的。"
188212

189-
#:../../c-api/float.rst:122
213+
#:../../c-api/float.rst:139
190214
msgid"``-0.0`` and ``+0.0`` produce the same bytes string."
191215
msgstr"``-0.0`` 和 ``+0.0`` 将产生相同的字节串。"
192216

193-
#:../../c-api/float.rst:126
217+
#:../../c-api/float.rst:143
194218
msgid"Pack a C double as the IEEE 754 binary16 half-precision format."
195219
msgstr"将 C double 打包为 IEEE 754 binary16 半精度格式。"
196220

197-
#:../../c-api/float.rst:130
221+
#:../../c-api/float.rst:147
198222
msgid"Pack a C double as the IEEE 754 binary32 single precision format."
199223
msgstr"将 C double 打包为 IEEE 754 binary32 单精度格式。"
200224

201-
#:../../c-api/float.rst:134
225+
#:../../c-api/float.rst:151
202226
msgid"Pack a C double as the IEEE 754 binary64 double precision format."
203227
msgstr"将 C double 打包为 IEEE 754 binary64 双精度格式。"
204228

205-
#:../../c-api/float.rst:138
229+
#:../../c-api/float.rst:155
206230
msgid"Unpack functions"
207231
msgstr"解包函数"
208232

209-
#:../../c-api/float.rst:140
233+
#:../../c-api/float.rst:157
210234
msgid""
211235
"The unpack routines read 2, 4 or 8 bytes, starting at *p*. *le* is an "
212236
":c:expr:`int` argument, non-zero if the bytes string is in little-endian "
@@ -220,7 +244,7 @@ msgstr ""
220244
"(指数部分放在前面,位于 *p*) 则其应为零。 :c:macro:`PY_BIG_ENDIAN` 常量可被用于使用本机端序:在大端序处理器上等于 "
221245
"``1``,在小端序处理器上则等于 ``0``。"
222246

223-
#:../../c-api/float.rst:147
247+
#:../../c-api/float.rst:164
224248
msgid""
225249
"Return value: The unpacked double. On error, this is ``-1.0`` and "
226250
":c:func:`PyErr_Occurred` is true (and an exception is set, most likely "
@@ -229,21 +253,21 @@ msgstr ""
229253
"返回值: 解包后的 double。 出错时,返回值为 ``-1.0`` 且 :c:func:`PyErr_Occurred` 为真值 "
230254
"(并且会设置一个异常,最大可能为 :exc:`OverflowError`)。"
231255

232-
#:../../c-api/float.rst:151
256+
#:../../c-api/float.rst:168
233257
msgid""
234258
"Note that on a non-IEEE platform this will refuse to unpack a bytes string "
235259
"that represents a NaN or infinity."
236260
msgstr"请注意在非 IEEE 平台上此函数将拒绝解包表示 NaN 或无穷大的字节串。"
237261

238-
#:../../c-api/float.rst:156
262+
#:../../c-api/float.rst:173
239263
msgid"Unpack the IEEE 754 binary16 half-precision format as a C double."
240264
msgstr"将 IEEE 754 binary16 半精度格式解包为 C double。"
241265

242-
#:../../c-api/float.rst:160
266+
#:../../c-api/float.rst:177
243267
msgid"Unpack the IEEE 754 binary32 single precision format as a C double."
244268
msgstr"将 IEEE 754 binary32 单精度格式解包为 C double。"
245269

246-
#:../../c-api/float.rst:164
270+
#:../../c-api/float.rst:181
247271
msgid"Unpack the IEEE 754 binary64 double precision format as a C double."
248272
msgstr"将 IEEE 754 binary64 双精度格式解包为 C double。"
249273

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp