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

Commit353eec2

Browse files
github-actions[bot]mattwang44
authored andcommitted
sync with cpython b9c5ffe6
1 parent79b4c43 commit353eec2

File tree

10 files changed

+795
-775
lines changed

10 files changed

+795
-775
lines changed

‎library/datetime.po

Lines changed: 209 additions & 209 deletions
Large diffs are not rendered by default.

‎library/exceptions.po

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ msgid ""
88
msgstr ""
99
"Project-Id-Version:Python 3.12\n"
1010
"Report-Msgid-Bugs-To:\n"
11-
"POT-Creation-Date:2023-12-15 00:03+0000\n"
11+
"POT-Creation-Date:2023-12-16 00:03+0000\n"
1212
"PO-Revision-Date:2018-05-23 16:01+0000\n"
1313
"Last-Translator:Adrian Liaw <adrianliaw2000@gmail.com>\n"
1414
"Language-Team:Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
@@ -1115,11 +1115,11 @@ msgstr ""
11151115

11161116
#:../../library/exceptions.rst:1008
11171117
msgid""
1118-
"Note that :exc:`BaseExceptionGroup` defines :meth:`__new__`, so subclasses "
1119-
"that need a different constructor signature need to override that rather "
1120-
"than :meth:`__init__`. For example, the following defines an exception group "
1121-
"subclass which accepts an exit_code and and constructs the group's message "
1122-
"from it. ::"
1118+
"Note that :exc:`BaseExceptionGroup` defines :meth:`~object.__new__`, so "
1119+
"subclassesthat need a different constructor signature need to override that "
1120+
"ratherthan :meth:`~object.__init__`. For example, the following defines an "
1121+
"exception groupsubclass which accepts an exit_code and and constructs the "
1122+
"group's messagefrom it. ::"
11231123
msgstr""
11241124

11251125
#:../../library/exceptions.rst:1023

‎library/itertools.po

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ msgid ""
77
msgstr ""
88
"Project-Id-Version:Python 3.12\n"
99
"Report-Msgid-Bugs-To:\n"
10-
"POT-Creation-Date:2023-12-15 00:03+0000\n"
10+
"POT-Creation-Date:2023-12-16 00:03+0000\n"
1111
"PO-Revision-Date:2018-05-23 16:04+0000\n"
1212
"Last-Translator:Adrian Liaw <adrianliaw2000@gmail.com>\n"
1313
"Language-Team:Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
@@ -889,6 +889,6 @@ msgid ""
889889
"term:`generator`\\s which incur interpreter overhead."
890890
msgstr""
891891

892-
#:../../library/itertools.rst:1024
892+
#:../../library/itertools.rst:1025
893893
msgid"The following recipes have a more mathematical flavor:"
894894
msgstr""

‎library/numbers.po

Lines changed: 33 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ msgid ""
99
msgstr ""
1010
"Project-Id-Version:Python 3.12\n"
1111
"Report-Msgid-Bugs-To:\n"
12-
"POT-Creation-Date:2022-10-1604:24+0800\n"
12+
"POT-Creation-Date:2023-12-1600:03+0000\n"
1313
"PO-Revision-Date:2022-11-16 04:57+0800\n"
1414
"Last-Translator:Matt Wang <mattwang44@gmail.com>\n"
1515
"Language-Team:Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
@@ -30,11 +30,12 @@ msgid "**Source code:** :source:`Lib/numbers.py`"
3030
msgstr"**原始碼:**\\ :source:`Lib/numbers.py`"
3131

3232
#:../../library/numbers.rst:11
33+
#,fuzzy
3334
msgid""
34-
"The :mod:`numbers` module (:pep:`3141`) defines a hierarchy of numeric:term:"
35-
"`abstract base classes <abstract base class>` which progressively define "
36-
"more operations. None of the types defined in this module are intended to "
37-
"be instantiated."
35+
"The :mod:`!numbers` module (:pep:`3141`) defines a hierarchy of numeric :"
36+
"term:`abstract base classes <abstract base class>` which progressively "
37+
"definemore operations. None of the types defined in this module are "
38+
"intended tobe instantiated."
3839
msgstr""
3940
":mod:`numbers` 模組 (:pep:`3141`) 定義了數值\\ :term:`抽象基底類別 <abstract "
4041
"base class>` 的階層結構,其中逐一定義了更多操作。此模組中定義的型別都不可被實"
@@ -80,8 +81,9 @@ msgid ""
8081
msgstr"為抽象的。回傳共軛複數,例如 ``(1+3j).conjugate() == (1-3j)``。"
8182

8283
#:../../library/numbers.rst:48
84+
#,fuzzy
8385
msgid""
84-
"To :class:`Complex`, :class:`Real` adds the operations that work on real "
86+
"To :class:`Complex`, :class:`!Real` adds the operations that work on real "
8587
"numbers."
8688
msgstr"相對於 :class:`Complex`,:class:`Real` 加入了只有實數才能進行的操作。"
8789

@@ -174,20 +176,21 @@ msgid "Implementing the arithmetic operations"
174176
msgstr"實作算術操作"
175177

176178
#:../../library/numbers.rst:125
179+
#,fuzzy
177180
msgid""
178181
"We want to implement the arithmetic operations so that mixed-mode operations "
179182
"either call an implementation whose author knew about the types of both "
180183
"arguments, or convert both to the nearest built in type and do the operation "
181-
"there. For subtypes of :class:`Integral`, this means that :meth:`__add__`"
182-
"and :meth:`__radd__` should be defined as::"
184+
"there. For subtypes of :class:`Integral`, this means that :meth:`~object."
185+
"__add__`and :meth:`~object.__radd__` should be defined as::"
183186
msgstr""
184187
"我們想要實作算術操作,來使得混合模式操作要麼呼叫一個作者知道兩個引數之型別的"
185188
"實作,要麼將其轉換成最接近的內建型別並執行這個操作。對於 :class:`Integral` 的"
186189
"子型別,這意味著 :meth:`__add__` 和 :meth:`__radd__` 必須用如下方式定義:\n"
187190
"\n"
188191
"::"
189192

190-
#:../../library/numbers.rst:156
193+
#:../../library/numbers.rst:157
191194
msgid""
192195
"There are 5 different cases for a mixed-type operation on subclasses of :"
193196
"class:`Complex`. I'll refer to all of the above code that doesn't refer to "
@@ -200,38 +203,42 @@ msgstr ""
200203
"(boilerplate)」。``a`` 是 :class:`Complex` 之子型別 ``A`` 的實例 (``a : A <: "
201204
"Complex``),同時 ``b : B <: Complex``。我將要計算 ``a + b``:"
202205

203-
#:../../library/numbers.rst:163
204-
msgid"If ``A`` defines an :meth:`__add__` which accepts ``b``, all is well."
206+
#:../../library/numbers.rst:164
207+
#,fuzzy
208+
msgid""
209+
"If ``A`` defines an :meth:`~object.__add__` which accepts ``b``, all is well."
205210
msgstr"如果 ``A`` 有定義成一個接受 ``b`` 的 :meth:`__add__`,不會發生問題。"
206211

207-
#:../../library/numbers.rst:165
212+
#:../../library/numbers.rst:166
213+
#,fuzzy
208214
msgid""
209215
"If ``A`` falls back to the boilerplate code, and it were to return a value "
210-
"from :meth:`__add__`, we'd miss the possibility that ``B`` defines a more "
211-
"intelligent :meth:`__radd__`, so the boilerplate should return:const:"
212-
"`NotImplemented` from :meth:`__add__`. (Or ``A`` may not implement:meth:"
213-
"`__add__` at all.)"
216+
"from :meth:`~object.__add__`, we'd miss the possibility that ``B`` defines a "
217+
"moreintelligent :meth:`~object.__radd__`, so the boilerplate should return :"
218+
"const:`NotImplemented` from :meth:`!__add__`. (Or ``A`` may not implement :"
219+
"meth:`!__add__` at all.)"
214220
msgstr""
215221
"如果 ``A`` 回退成模板程式碼,它將回傳一個來自 :meth:`__add__` 的值,並喪失讓 "
216222
"``B`` 定義一個更完善的 :meth:`__radd__` 的機會,因此模板需要回傳一個來自 :"
217223
"meth:`__add__` 的 :const:`NotImplemented`。(或者 ``A`` 可能完全不實作 :meth:"
218224
"`__add__`。)"
219225

220-
#:../../library/numbers.rst:171
226+
#:../../library/numbers.rst:172
227+
#,fuzzy
221228
msgid""
222-
"Then ``B``'s :meth:`__radd__` gets a chance. If it accepts ``a``, all is "
223-
"well."
229+
"Then ``B``'s :meth:`~object.__radd__` gets a chance. If it accepts ``a``, "
230+
"all iswell."
224231
msgstr"接著看 ``B`` 的 :meth:`__radd__`。如果它接受 ``a`` ,不會發生問題。"
225232

226-
#:../../library/numbers.rst:173
233+
#:../../library/numbers.rst:174
227234
msgid""
228235
"If it falls back to the boilerplate, there are no more possible methods to "
229236
"try, so this is where the default implementation should live."
230237
msgstr""
231238
"如果沒有成功回退到模板,就沒有更多的方法可以去嘗試,因此這裡將使用預設的實"
232239
"作。"
233240

234-
#:../../library/numbers.rst:176
241+
#:../../library/numbers.rst:177
235242
msgid""
236243
"If ``B <: A``, Python tries ``B.__radd__`` before ``A.__add__``. This is ok, "
237244
"because it was implemented with knowledge of ``A``, so it can handle those "
@@ -241,17 +248,19 @@ msgstr ""
241248
"的,因為它是透過對 ``A`` 的理解而實作的,所以這可以在交給 :class:`Complex` 之"
242249
"前處理好這些實例。"
243250

244-
#:../../library/numbers.rst:181
251+
#:../../library/numbers.rst:182
252+
#,fuzzy
245253
msgid""
246254
"If ``A <: Complex`` and ``B <: Real`` without sharing any other knowledge, "
247255
"then the appropriate shared operation is the one involving the built in :"
248-
"class:`complex`, and both :meth:`__radd__` s land there, so ``a+b == b+a``."
256+
"class:`complex`, and both :meth:`~object.__radd__` s land there, so ``a+b == "
257+
"b+a``."
249258
msgstr""
250259
"如果 ``A <: Complex`` 和 ``B <: Real`` 且沒有共享任何其他型別上的理解,那麼適"
251260
"當的共享操作會涉及內建的 :class:`complex`,並且分別用到 :meth:`__radd__`,因"
252261
"此 ``a+b == b+a``。"
253262

254-
#:../../library/numbers.rst:186
263+
#:../../library/numbers.rst:187
255264
msgid""
256265
"Because most of the operations on any given type will be very similar, it "
257266
"can be useful to define a helper function which generates the forward and "

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp