Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 45e9fdf

Browse files
[po] auto sync
1 parent 0d7abdf commit 45e9fdf

2 files changed

Lines changed: 33 additions & 32 deletions

File tree

.stat.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{"translation": "92.53%", "updated_at": "2023-11-27T04:55:53Z"}
1+
{"translation": "92.53%", "updated_at": "2023-11-27T05:55:37Z"}

library/array.po

Lines changed: 32 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -271,7 +271,7 @@ msgid ""
271271
"object>` are supported."
272272
msgstr ""
273273
"数组对象支持普通的序列操作如索引、切片、拼接和重复等。当使用切片赋值时,所赋的值必须为具有相同类型码的数组对象;所有其他情况都将引发 "
274-
":exc:`TypeError`。数组对象也实现了缓冲区接口,可以用于所有支持 :term:`字节类对象 <bytes-like object>` "
274+
":exc:`TypeError`。数组对象也实现了缓冲区接口,可以用于所有支持 :term:`类字节对象 <bytes-like object>` "
275275
"的场合。"
276276

277277
#: ../../library/array.rst:94
@@ -318,8 +318,9 @@ msgid ""
318318
"backward compatibility and should be avoided in new code. The buffer "
319319
"interface is documented in :ref:`bufferobjects`."
320320
msgstr ""
321-
"当在 C 或 C++ 编写的代码中使用数组对象时(这是有效使用此类信息的唯一方式),使用数组对象所支持的缓冲区接口更为适宜。 "
322-
"此方法仅保留用作向下兼容,应避免在新代码中使用。 缓冲区接口的文档参见 :ref:`bufferobjects`。"
321+
"只有在使用以 C 或 C++ "
322+
"编写的代码中的数组对象时,才能有效利用该信息,但此时,更合理的是,使用数组对象支持的缓冲区接口。因此,该方法的存在仅仅是为了向后兼容性,应避免在新代码中使用。缓冲区接口的文档参见"
323+
" :ref:`bufferobjects`。"
323324

324325
#: ../../library/array.rst:133
325326
msgid ""
@@ -328,8 +329,8 @@ msgid ""
328329
":exc:`RuntimeError` is raised. It is useful when reading data from a file "
329330
"written on a machine with a different byte order."
330331
msgstr ""
331-
"“字节对调”所有数组项。 此方法只支持大小为 1, 2, 4 或 8 字节的值;对于其他值类型将引发 :exc:`RuntimeError`。 "
332-
"它适用于从不同字节序机器所生成的文件中读取数据的情况。"
332+
"“字节对调”所有数组项。此方法只支持大小为 1, 2, 4 或 8 字节的值;对于其它类型的值将引发 "
333+
":exc:`RuntimeError`。当要从另一种字节顺序的机器生成的文件中读取数据时,它很有用。"
333334

334335
#: ../../library/array.rst:141
335336
msgid "Return the number of occurrences of *x* in the array."
@@ -343,15 +344,15 @@ msgid ""
343344
"iterable and its elements must be the right type to be appended to the "
344345
"array."
345346
msgstr ""
346-
"将来自 *iterable* 的项添加到数组末尾。 如果 *iterable* 是另一个数组,它必须具有 *完全* 相同的类型码;否则将引发 "
347-
":exc:`TypeError`。 如果 *iterable* 不是一个数组,则它必须为可迭代对象并且其元素必须为可添加到数组的适当类型。"
347+
"将来自 *iterable* 的项添加到数组末尾。如果 *iterable* 是另一个数组,它必须具有 *完全* 相同的类型码;否则将引发 "
348+
":exc:`TypeError`。如果 *iterable* 不是一个数组,则它必须为可迭代对象且其元素的类型须为可添加到数组的适当类型。"
348349

349350
#: ../../library/array.rst:154
350351
msgid ""
351352
"Appends items from the string, interpreting the string as an array of "
352353
"machine values (as if it had been read from a file using the "
353354
":meth:`fromfile` method)."
354-
msgstr "添加来自字节串的项,将字符节解读为机器值的数组(相当于使用 :meth:`fromfile` 方法从文件中读取数据)。"
355+
msgstr "将来自字节串的项添加到数组末尾,字节串被视为由机器值组成的数组(就像用 :meth:`fromfile` 方法从文件中读取数据一样)。"
355356

356357
#: ../../library/array.rst:157
357358
msgid ":meth:`!fromstring` is renamed to :meth:`frombytes` for clarity."
@@ -364,15 +365,15 @@ msgid ""
364365
":exc:`EOFError` is raised, but the items that were available are still "
365366
"inserted into the array."
366367
msgstr ""
367-
"从 :term:`file object` *f* 中读取 *n* 项并将它们添加到数组末尾。 如果可用数据少于 *n* 项,则会引发 "
368-
":exc:`EOFError`,但可用的项仍然会被插入数组。"
368+
"从 :term:`file object` *f* 中读取 *n* 项(视为机器值)并将它们添加到数组末尾。如果可用的项少于 *n* 项,则会引发 "
369+
":exc:`EOFError`,但可用的项仍然会被加进数组。"
369370

370371
#: ../../library/array.rst:171
371372
msgid ""
372373
"Append items from the list. This is equivalent to ``for x in list: "
373374
"a.append(x)`` except that if there is a type error, the array is unchanged."
374375
msgstr ""
375-
"添加来自 list 的项。 这等价于 ``for x in list: a.append(x)``,区别在于如果发生类型错误,数组将不会被改变。"
376+
"将来自列表的项添加到数组末尾。等价于 ``for x in list: a.append(x)``,而不同之处在于,若发生类型错误,数组则不会被改变。"
376377

377378
#: ../../library/array.rst:177
378379
msgid ""
@@ -381,8 +382,8 @@ msgid ""
381382
"``array.frombytes(unicodestring.encode(enc))`` to append Unicode data to an "
382383
"array of some other type."
383384
msgstr ""
384-
"使用来自给定 Unicode 字符串的数组扩展数组。 数组必须是类型为 ``'u'`` 的数组;否则将引发 :exc:`ValueError`。 请使用"
385-
" ``array.frombytes(unicodestring.encode(enc))`` 来将 Unicode 数据添加到其他类型的数组。"
385+
"将来自 Unicode 字符串的项添加到数组末尾。数组必须是类型为 ``'u'`` 的数组;否则将引发 :exc:`ValueError`。请用 "
386+
"``array.frombytes(unicodestring.encode(enc))`` 来将 Unicode 数据添加到其它类型的数组。"
386387

387388
#: ../../library/array.rst:185
388389
msgid ""
@@ -391,8 +392,8 @@ msgid ""
391392
"specified to search for *x* within a subsection of the array. Raise "
392393
":exc:`ValueError` if *x* is not found."
393394
msgstr ""
394-
"返回最小的 *i* 使得 *i* 为数组中首次出现的 *x* 的索引号。 指定可选参数 *start* 和 *stop* 以便在数组的一个子部分内部搜索"
395-
" *x*。 如果未找到 *x* 则会引发 :exc:`ValueError`。"
395+
"返回以这样的方式找到的最小的 *i**i* 为数组中第一个 *x* 的下标。可选参数 *start* 和 *stop* "
396+
"用于在数组的一个指定的子段中搜索 *x*。如果未找到 *x* 则会引发 :exc:`ValueError`。"
396397

397398
#: ../../library/array.rst:190
398399
msgid "Added optional *start* and *stop* parameters."
@@ -402,18 +403,18 @@ msgstr "添加了可选的 *start* 和 *stop* 形参。"
402403
msgid ""
403404
"Insert a new item with value *x* in the array before position *i*. Negative "
404405
"values are treated as being relative to the end of the array."
405-
msgstr "将值 *x* 作为新项插入数组的 *i* 位置之前。 负值将被视为相对于数组末尾的位置。"
406+
msgstr "在数组的位置 *i* 之前插入一个值为 *x* 的新项。负值被视为相对于数组末尾的位置。"
406407

407408
#: ../../library/array.rst:202
408409
msgid ""
409410
"Removes the item with the index *i* from the array and returns it. The "
410411
"optional argument defaults to ``-1``, so that by default the last item is "
411412
"removed and returned."
412-
msgstr "从数组中移除序号为 *i* 的项并将其返回。 可选参数值默认为 ``-1``,因此默认将移除并返回末尾项。"
413+
msgstr "从数组中移除下标为 *i* 的项并将其返回。参数默认值为 ``-1``,因此默认移除并返回末项。"
413414

414415
#: ../../library/array.rst:209
415416
msgid "Remove the first occurrence of *x* from the array."
416-
msgstr "从数组中移除首次出现的 *x*。"
417+
msgstr "从数组中移除第一个出现的 *x*。"
417418

418419
#: ../../library/array.rst:214
419420
msgid "Reverse the order of the items in the array."
@@ -424,19 +425,19 @@ msgid ""
424425
"Convert the array to an array of machine values and return the bytes "
425426
"representation (the same sequence of bytes that would be written to a file "
426427
"by the :meth:`tofile` method.)"
427-
msgstr "将数组转换为一个机器值数组并返回其字节表示(即相当与通过 :meth:`tofile` 方法写入到文件的字节序列。)"
428+
msgstr "将数组转换为一个由机器值组成的数组并返回其字节表示(和用 :meth:`tofile` 方法写入文件的字节序列相同)。"
428429

429430
#: ../../library/array.rst:223
430431
msgid ":meth:`!tostring` is renamed to :meth:`tobytes` for clarity."
431432
msgstr ":meth:`!tostring` 被重命名为含义更准确的 :meth:`tobytes`。"
432433

433434
#: ../../library/array.rst:229
434435
msgid "Write all items (as machine values) to the :term:`file object` *f*."
435-
msgstr "将所有项(作为机器值)写入到 :term:`file object` *f*。"
436+
msgstr "将所有项(作为机器值)写入 :term:`file object` *f*。"
436437

437438
#: ../../library/array.rst:234
438439
msgid "Convert the array to an ordinary list with the same items."
439-
msgstr "将数组转换为包含相同项的普通列表。"
440+
msgstr "将数组转换为由相同的项组成的普通列表。"
440441

441442
#: ../../library/array.rst:239
442443
msgid ""
@@ -445,8 +446,8 @@ msgid ""
445446
"``array.tobytes().decode(enc)`` to obtain a unicode string from an array of "
446447
"some other type."
447448
msgstr ""
448-
"将数组转换为一个 Unicode 字符串。 数组必须是类型为 ``'u'`` 的数组;否则将引发 :exc:`ValueError`。 请使用 "
449-
"``array.tobytes().decode(enc)`` 来从其他类型的数组生成 Unicode 字符串。"
449+
"将数组转换为一个 Unicode 字符串。数组必须是类型为 ``'u'`` 的数组;否则将引发 :exc:`ValueError`。请用 "
450+
"``array.tobytes().decode(enc)`` 来将其它类型的数组转换为 Unicode 字符串。"
450451

451452
#: ../../library/array.rst:244
452453
msgid ""
@@ -458,36 +459,36 @@ msgid ""
458459
":func:`eval`, so long as the :class:`~array.array` class has been imported "
459460
"using ``from array import array``. Examples::"
460461
msgstr ""
461-
"当一个数组对象被打印或转换为字符串时,它会表示为 ``array(typecode, initializer)``。 如果数组为空则 "
462-
"*initializer* 会被省略,否则如果 *typecode* 为 ``'u'`` 则它是一个字符串,否则它是一个数字列表。 使用 "
463-
":func:`eval` 保证能将字符串转换回具有相同类型和值的数组,只要 :class:`~array.array` 类已通过 ``from "
464-
"array import array`` 被引入。 例如::"
462+
"数组对象被打印或转换为字符串时,会被表示为 ``array(typecode, initializer)``。*initializer* "
463+
"在数组为空时会被省略,在数组的 *typecode* 为 ``'u'`` 时是一个字符串,其它时候是一个数字列表。只要 "
464+
":class:`~array.array` 类已用 ``from array import array`` 引入,该字符串保证能被 "
465+
":func:`eval` 转换回具有相同类型和值的数组。例:"
465466

466467
#: ../../library/array.rst:261
467468
msgid "Module :mod:`struct`"
468-
msgstr "模块 :mod:`struct`"
469+
msgstr ":mod:`struct` 模块"
469470

470471
#: ../../library/array.rst:261
471472
msgid "Packing and unpacking of heterogeneous binary data."
472473
msgstr "打包和解包异构二进制数据。"
473474

474475
#: ../../library/array.rst:265
475476
msgid "Module :mod:`xdrlib`"
476-
msgstr "模块 :mod:`xdrlib`"
477+
msgstr ":mod:`xdrlib` 模块"
477478

478479
#: ../../library/array.rst:264
479480
msgid ""
480481
"Packing and unpacking of External Data Representation (XDR) data as used in "
481482
"some remote procedure call systems."
482-
msgstr "打包和解包用于某些远程过程调用系统的 External Data Representation (XDR) 数据。"
483+
msgstr "打包和解包某些远程过程调用系统使用的 External Data Representation (XDR) 数据。"
483484

484485
#: ../../library/array.rst:267
485486
msgid "`NumPy <https://numpy.org/>`_"
486487
msgstr "`NumPy <https://numpy.org/>`_"
487488

488489
#: ../../library/array.rst:268
489490
msgid "The NumPy package defines another array type."
490-
msgstr "NumPy 软件包定义了另一种数组类型。"
491+
msgstr "NumPy 包定义了另一数组类型。"
491492

492493
#: ../../library/array.rst:7
493494
msgid "arrays"

0 commit comments

Comments
 (0)