Skip to content

Commit a1b884a

Browse files
authored
Merge branch '3.13' into grp-trans
2 parents 9ebe414 + f8fa2e6 commit a1b884a

File tree

4 files changed

+72
-18
lines changed

4 files changed

+72
-18
lines changed

c-api/marshal.po

Lines changed: 39 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,28 @@
1-
# SOME DESCRIPTIVE TITLE.
2-
# Copyright (C) 2001-2022, Python Software Foundation
1+
# Copyright (C) 2001-2025, Python Software Foundation
32
# This file is distributed under the same license as the Python package.
43
#
54
# Translators:
5+
# Adrian Liaw <adrianliaw2000@gmail.com>, 2018
6+
# Matt Wang <mattwang44@gmail.com>, 2025
67
msgid ""
78
msgstr ""
89
"Project-Id-Version: Python 3.13\n"
910
"Report-Msgid-Bugs-To: \n"
1011
"POT-Creation-Date: 2024-07-20 00:03+0000\n"
11-
"PO-Revision-Date: 2018-05-23 14:06+0000\n"
12-
"Last-Translator: Adrian Liaw <adrianliaw2000@gmail.com>\n"
12+
"PO-Revision-Date: 2025-06-28 02:44+0800\n"
13+
"Last-Translator: Matt Wang <mattwang44@gmail.com>\n"
1314
"Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
1415
"tw)\n"
1516
"Language: zh_TW\n"
1617
"MIME-Version: 1.0\n"
1718
"Content-Type: text/plain; charset=UTF-8\n"
1819
"Content-Transfer-Encoding: 8bit\n"
1920
"Plural-Forms: nplurals=1; plural=0;\n"
21+
"X-Generator: Poedit 3.6\n"
2022

2123
#: ../../c-api/marshal.rst:6
2224
msgid "Data marshalling support"
23-
msgstr "資料 marshal 的支援"
25+
msgstr "資料 marshal 操作的支援"
2426

2527
#: ../../c-api/marshal.rst:8
2628
msgid ""
@@ -30,10 +32,13 @@ msgid ""
3032
"read the data back. Files used to store marshalled data must be opened in "
3133
"binary mode."
3234
msgstr ""
35+
"這些例程允許 C 程式碼使用與 :mod:`marshal` 模組相同的資料格式來處理序列化物"
36+
"件。有函式可以將資料寫入序列化格式,還有其他函式可以用來讀取回資料。用來儲存 "
37+
"marshal 過的資料的檔案必須以二進位模式開啟。"
3338

3439
#: ../../c-api/marshal.rst:14
3540
msgid "Numeric values are stored with the least significant byte first."
36-
msgstr ""
41+
msgstr "數值會以最低有效位元組 (the least significant byte) 優先的方式儲存。"
3742

3843
#: ../../c-api/marshal.rst:16
3944
msgid ""
@@ -42,68 +47,85 @@ msgid ""
4247
"unmarshalling. Version 2 uses a binary format for floating-point numbers. "
4348
"``Py_MARSHAL_VERSION`` indicates the current file format (currently 2)."
4449
msgstr ""
50+
"這個模組支援兩個版本的資料格式:版本 0 是歷史版本,版本 1 在檔案中共享駐留字"
51+
"串 (interned strings),並在 unmarshal 時使用。版本 2 使用二進位格式來儲存浮點"
52+
"數。``Py_MARSHAL_VERSION`` 表示目前的檔案格式(目前為 2)。"
4553

4654
#: ../../c-api/marshal.rst:24
4755
msgid ""
4856
"Marshal a :c:expr:`long` integer, *value*, to *file*. This will only write "
4957
"the least-significant 32 bits of *value*; regardless of the size of the "
5058
"native :c:expr:`long` type. *version* indicates the file format."
5159
msgstr ""
60+
"將一個 :c:expr:`long` 整數 *value* marshal 為 *file*。這只會寫入 *value* 的最"
61+
"低有效 32 位元;無論原生 :c:expr:`long` 型別的大小如何。*version* 表示檔案的格"
62+
"式。"
5263

5364
#: ../../c-api/marshal.rst:28 ../../c-api/marshal.rst:36
5465
msgid ""
55-
"This function can fail, in which case it sets the error indicator. Use :c:"
56-
"func:`PyErr_Occurred` to check for that."
66+
"This function can fail, in which case it sets the error indicator. "
67+
"Use :c:func:`PyErr_Occurred` to check for that."
5768
msgstr ""
69+
"這個函式可能會失敗,這時會設定錯誤指示器。使用 :c:func:`PyErr_Occurred` 來檢"
70+
"查是否發生錯誤。"
5871

5972
#: ../../c-api/marshal.rst:33
6073
msgid ""
6174
"Marshal a Python object, *value*, to *file*. *version* indicates the file "
6275
"format."
6376
msgstr ""
77+
"將一個 Python 物件 *value* marshal 為 *file*。*version* 表示檔案的格式。"
6478

6579
#: ../../c-api/marshal.rst:41
6680
msgid ""
6781
"Return a bytes object containing the marshalled representation of *value*. "
6882
"*version* indicates the file format."
6983
msgstr ""
84+
"回傳一個位元組物件,包含 *value* 的 marshal 表示。*version* 為檔案的格式。"
7085

7186
#: ../../c-api/marshal.rst:45
7287
msgid "The following functions allow marshalled values to be read back in."
73-
msgstr ""
88+
msgstr "以下函式允許將 marshal 過後的值讀取回來。"
7489

7590
#: ../../c-api/marshal.rst:50
7691
msgid ""
7792
"Return a C :c:expr:`long` from the data stream in a :c:expr:`FILE*` opened "
7893
"for reading. Only a 32-bit value can be read in using this function, "
7994
"regardless of the native size of :c:expr:`long`."
8095
msgstr ""
96+
"從一個為讀取而開啟的 :c:expr:`FILE*` 中的資料串流回傳一個 C :c:expr:`long`。"
97+
"無論 :c:expr:`long` 的原生大小如何,這個函式只能讀取 32 位元的值。"
8198

8299
#: ../../c-api/marshal.rst:54 ../../c-api/marshal.rst:64
83100
msgid ""
84101
"On error, sets the appropriate exception (:exc:`EOFError`) and returns "
85102
"``-1``."
86-
msgstr ""
103+
msgstr "在錯誤發生時,會設定合適的例外(:exc:`EOFError`)並回傳 ``-1``。"
87104

88105
#: ../../c-api/marshal.rst:60
89106
msgid ""
90107
"Return a C :c:expr:`short` from the data stream in a :c:expr:`FILE*` opened "
91108
"for reading. Only a 16-bit value can be read in using this function, "
92109
"regardless of the native size of :c:expr:`short`."
93110
msgstr ""
111+
"從一個為讀取而開啟的 :c:expr:`FILE*` 中的資料串流回傳一個 C :c:expr:`short`。"
112+
"無論 :c:expr:`short` 的原生大小如何,這個函式只能讀取 16 位元的值。"
94113

95114
#: ../../c-api/marshal.rst:70
96115
msgid ""
97116
"Return a Python object from the data stream in a :c:expr:`FILE*` opened for "
98117
"reading."
99118
msgstr ""
119+
"從一個為讀取而開啟的 :c:expr:`FILE*` 中的資料串流回傳一個 Python 物件。"
100120

101121
#: ../../c-api/marshal.rst:73 ../../c-api/marshal.rst:87
102122
#: ../../c-api/marshal.rst:96
103123
msgid ""
104124
"On error, sets the appropriate exception (:exc:`EOFError`, :exc:`ValueError` "
105125
"or :exc:`TypeError`) and returns ``NULL``."
106126
msgstr ""
127+
"在錯誤發生時,會設定合適的例外(:exc:`EOFError`、:exc:`ValueError` "
128+
"或 :exc:`TypeError`)並回傳 ``NULL``。"
107129

108130
#: ../../c-api/marshal.rst:79
109131
msgid ""
@@ -115,9 +137,16 @@ msgid ""
115137
"file. Only use these variant if you are certain that you won't be reading "
116138
"anything else from the file."
117139
msgstr ""
140+
"從一個為讀取而開啟的 :c:expr:`FILE*` 中的資料串流回傳一個 Python 物件。"
141+
"與 :c:func:`PyMarshal_ReadObjectFromFile` 不同,這個函式假設不會從檔案中讀取"
142+
"其他物件,允許它積極地將檔案資料載入記憶體,以便反序列化可以從記憶體中的資料"
143+
"操作,而不是從檔案中逐位元組讀取。只有在確定不會從檔案中讀取其他內容時,才使"
144+
"用這個變體。"
118145

119146
#: ../../c-api/marshal.rst:93
120147
msgid ""
121148
"Return a Python object from the data stream in a byte buffer containing "
122149
"*len* bytes pointed to by *data*."
123150
msgstr ""
151+
"從一個包含 *len* 位元組、被 *data* 指向的位元組緩衝區中的資料串流回傳一個 "
152+
"Python 物件。"

library/custominterp.po

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,13 @@
33
# This file is distributed under the same license as the Python package.
44
#
55
# Translators:
6+
# Weilin Du, 2025
67
msgid ""
78
msgstr ""
89
"Project-Id-Version: Python 3.13\n"
910
"Report-Msgid-Bugs-To: \n"
1011
"POT-Creation-Date: 2022-07-06 00:17+0000\n"
11-
"PO-Revision-Date: 2015-12-09 17:51+0000\n"
12+
"PO-Revision-Date: 2025-06-28 10:57+0800\n"
1213
"Last-Translator: Liang-Bo Wang <me@liang2.tw>\n"
1314
"Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
1415
"tw)\n"
@@ -30,6 +31,9 @@ msgid ""
3031
"look at the :mod:`code` module. (The :mod:`codeop` module is lower-level, "
3132
"used to support compiling a possibly incomplete chunk of Python code.)"
3233
msgstr ""
34+
"本章介紹的模組可用於編寫類似於 Python 交互式直譯器的介面。如果你需要一個在 "
35+
"Python 語言基礎上支援某些特殊功能的直譯器,可以參考 :mod:`code` 模組。("
36+
" :mod:`codeop` 模組屬於底層工具,用於支援編譯可能不完整的 Python 程式碼。)"
3337

3438
#: ../../library/custominterp.rst:13
3539
msgid "The full list of modules described in this chapter is:"

library/superseded.po

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,21 @@
33
#
44
# Translators:
55
# Matt Wang <mattwang44@gmail.com>, 2022
6+
# Weilin Du, 2025
67
msgid ""
78
msgstr ""
89
"Project-Id-Version: Python 3.13\n"
910
"Report-Msgid-Bugs-To: \n"
1011
"POT-Creation-Date: 2024-12-29 11:18+0000\n"
11-
"PO-Revision-Date: 2022-02-15 20:45+0800\n"
12-
"Last-Translator: Matt Wang <mattwang44@gmail.com>\n"
12+
"PO-Revision-Date: 2025-06-28 12:28+0800\n"
13+
"Last-Translator: Weilin Du <mattwang44@gmail.com>\n"
1314
"Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
1415
"tw)\n"
1516
"Language: zh_TW\n"
1617
"MIME-Version: 1.0\n"
1718
"Content-Type: text/plain; charset=UTF-8\n"
1819
"Content-Transfer-Encoding: 8bit\n"
1920
"Plural-Forms: nplurals=1; plural=0;\n"
20-
"X-Generator: Poedit 3.0.1\n"
2121

2222
#: ../../library/superseded.rst:5
2323
msgid "Superseded Modules"
@@ -41,6 +41,11 @@ msgid ""
4141
"rather than the broader command line option parsing and argument parsing "
4242
"capabilities offered by :mod:`optparse` and :mod:`argparse`)."
4343
msgstr ""
44+
"某些模組出現在本章節,可能是因為它們能解決的問題是問題空間的有限子集,而標準函"
45+
"式庫的其他地方提供了更通用的解決方案(例如,:mod:`getopt` 只處理「在 Python "
46+
"中模擬 C 語言中 :c:func:`!getopt` 這個 API 」這項非常具體的任務,而非像 :mod:"
47+
"`optparse` 和 :mod:`argparse` 那樣提供更廣泛的命令列選項剖析與引數剖析功"
48+
"能)。"
4449

4550
#: ../../library/superseded.rst:17
4651
msgid ""
@@ -50,3 +55,7 @@ msgid ""
5055
"projects. With the removal of various obsolete modules through :pep:`594`, "
5156
"there are currently no modules in this latter category."
5257
msgstr ""
58+
"或者, 某些模組出現在本章節,可能是因為它們已被明確棄用(deprecated),並將"
59+
"在未來版本中移除;又或者它們屬於 :term:`soft deprecated` 狀態,官方強烈不建"
60+
"議在新專案中使用。隨著 :pep:`594` 移除了多個過時模組,目前標準函式庫中已不存"
61+
"在後者(軟性棄用)這類模組。"

library/tty.po

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,21 +5,21 @@
55
# Translators:
66
# Liang-Bo Wang <me@liang2.tw>, 2016
77
# Matt Wang <mattwang44@gmail.com>, 2021
8+
# Weilin Du, 2025
89
msgid ""
910
msgstr ""
1011
"Project-Id-Version: Python 3.13\n"
1112
"Report-Msgid-Bugs-To: \n"
1213
"POT-Creation-Date: 2024-10-11 00:13+0000\n"
13-
"PO-Revision-Date: 2021-12-17 17:00+0800\n"
14-
"Last-Translator: Matt Wang <mattwang44@gmail.com>\n"
14+
"PO-Revision-Date: 2025-06-28 20:38+0800\n"
15+
"Last-Translator: Weilin Du\n"
1516
"Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
1617
"tw)\n"
1718
"Language: zh_TW\n"
1819
"MIME-Version: 1.0\n"
1920
"Content-Type: text/plain; charset=UTF-8\n"
2021
"Content-Transfer-Encoding: 8bit\n"
2122
"Plural-Forms: nplurals=1; plural=0;\n"
22-
"X-Generator: Poedit 3.0.1\n"
2323

2424
#: ../../library/tty.rst:2
2525
msgid ":mod:`!tty` --- Terminal control functions"
@@ -37,7 +37,7 @@ msgstr ":mod:`tty` 模組定義了將 tty 放入 cbreak 和 raw 模式的函式
3737

3838
#: ../../library/tty.rst:18
3939
msgid "Availability"
40-
msgstr ""
40+
msgstr "可用性"
4141

4242
#: ../../library/tty.rst:20
4343
msgid ""
@@ -53,24 +53,32 @@ msgid ""
5353
"Convert the tty attribute list *mode*, which is a list like the one returned "
5454
"by :func:`termios.tcgetattr`, to that of a tty in raw mode."
5555
msgstr ""
56+
"將 tty 屬性串列 *mode* 轉換成原始模式下的 tty 屬性串列,這個串列就像 :func:"
57+
"`termios.tcgetattr` 所回傳的一樣。"
5658

5759
#: ../../library/tty.rst:35
5860
msgid ""
5961
"Convert the tty attribute list *mode*, which is a list like the one returned "
6062
"by :func:`termios.tcgetattr`, to that of a tty in cbreak mode."
6163
msgstr ""
64+
"將 tty 屬性串列 *mode* 轉換成 cbreak 模式下的 tty 屬性串列,這個串列就像 :"
65+
"func:`termios.tcgetattr` 所回傳的一樣。"
6266

6367
#: ../../library/tty.rst:38
6468
msgid ""
6569
"This clears the ``ECHO`` and ``ICANON`` local mode flags in *mode* as well "
6670
"as setting the minimum input to 1 byte with no delay."
6771
msgstr ""
72+
"這會清除 *mode* 中的 ``ECHO`` 和 ``ICANON`` 本地模式旗標,並將最小輸入設定為 "
73+
"1 位元組,且無延遲。"
6874

6975
#: ../../library/tty.rst:43
7076
msgid ""
7177
"The ``ICRNL`` flag is no longer cleared. This matches Linux and macOS ``stty "
7278
"cbreak`` behavior and what :func:`setcbreak` historically did."
7379
msgstr ""
80+
"不再清除 ``ICRNL`` 標記。這符合 Linux 和 macOS 的 ``stty cbreak`` 行為,也符"
81+
"合 :func:`setcbreak` 歷來的做法。"
7482

7583
#: ../../library/tty.rst:50
7684
msgid ""
@@ -106,13 +114,17 @@ msgid ""
106114
"This clears the ``ECHO`` and ``ICANON`` local mode flags as well as setting "
107115
"the minimum input to 1 byte with no delay."
108116
msgstr ""
117+
"這會清除 ``ECHO`` 和 ``ICANON`` 本地模式旗標,並將最小輸入設定為 1 位元組,且"
118+
"無延遲。"
109119

110120
#: ../../library/tty.rst:72
111121
msgid ""
112122
"The ``ICRNL`` flag is no longer cleared. This restores the behavior of "
113123
"Python 3.11 and earlier as well as matching what Linux, macOS, & BSDs "
114124
"describe in their ``stty(1)`` man pages regarding cbreak mode."
115125
msgstr ""
126+
"不再清除 ``ICRNL`` 旗標。這恢復了 Python 3.11 及更早版本的行為,也符合 "
127+
"Linux、macOS 及 BSD 在他們的 ``stty(1)`` man 頁面中描述的 cbreak 模式。"
116128

117129
#: ../../library/tty.rst:80
118130
msgid "Module :mod:`termios`"

0 commit comments

Comments
 (0)