6
6
# Translators:
7
7
# lit, 2024
8
8
# Rafael Fontenelle <[email protected] >, 2024
9
+ # AlexLin625, 2024
9
10
# Freesand Leo <[email protected] >, 2024
10
11
#
11
12
#, fuzzy
@@ -382,6 +383,8 @@ msgid ""
382
383
"``array.frombytes(unicodestring.encode(enc))`` to append Unicode data to an "
383
384
"array of some other type."
384
385
msgstr ""
386
+ "用给定的 Unicode 字符串中的数据扩展数组。 数组的类型代码必须是 ``'u'``,否则会引发 :exc:`ValueError` 异常。 使用 "
387
+ "``array.frombytes(unicodestring.encode(enc))`` 可将 Unicode 数据附加到其他类型的数组中。"
385
388
386
389
#: ../../library/array.rst:188
387
390
msgid ""
@@ -443,6 +446,8 @@ msgid ""
443
446
"otherwise a :exc:`ValueError` is raised. Use ``array.tobytes().decode(enc)``"
444
447
" to obtain a Unicode string from an array of some other type."
445
448
msgstr ""
449
+ "将数组转换为 Unicode 字符串。 数组的类型必须是 ``'u'``;否则会引发 :exc:`ValueError` 异常。 使用 "
450
+ "``array.tobytes().decode(enc)`` 可从其他类型的数组中获取 Unicode字符串。"
446
451
447
452
#: ../../library/array.rst:247
448
453
msgid ""
@@ -455,6 +460,11 @@ msgid ""
455
460
"using ``from array import array``. Variables ``inf`` and ``nan`` must also "
456
461
"be defined if it contains corresponding floating-point values. Examples::"
457
462
msgstr ""
463
+ "数组对象的字符串表示具有 ``array(typecode, initializer)`` 的形式。 当数组为空时,其中的 *initializer* "
464
+ "字段被省略;若 array 的类型代码是 ``'u'``,则 *initializer* 是一个 Unicode 字符串;其次则是一个数字列表。 "
465
+ "可以保证,用 :func:`eval` 能够将一个数组对象的字符串表示转换回一个具有相同类型和值的数组对象。 这需要用 ``from array "
466
+ "import array`` 语句引入 :class:`~array.array` 类。 若数组对象包括 Inf 或 NaN 浮点值,则相对应的 "
467
+ "``inf`` 和 ``nan`` 变量必须被定义。 举例如下::"
458
468
459
469
#: ../../library/array.rst:267
460
470
msgid "Module :mod:`struct`"
@@ -472,7 +482,7 @@ msgstr ":mod:`xdrlib` 模块"
472
482
msgid ""
473
483
"Packing and unpacking of External Data Representation (XDR) data as used in "
474
484
"some remote procedure call systems."
475
- msgstr ""
485
+ msgstr "对某些远程过程调用系统中使用的外部数据表示(XDR)数据进行打包和解包 。 "
476
486
477
487
#: ../../library/array.rst:274
478
488
msgid "`NumPy <https://numpy.org/>`_"
0 commit comments