8000 Refine translation of library/enum.po and library/exceptions.po · python/python-docs-zh-tw@4e2f664 · GitHub
[go: up one dir, main page]

Skip to content

Commit 4e2f664

Browse files
committed
Refine translation of library/enum.po and library/exceptions.po
1 parent 8aa15ac commit 4e2f664

File tree

2 files changed

+22
-22
lines changed

2 files changed

+22
-22
lines changed

library/enum.po

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -209,7 +209,7 @@ msgid ""
209209
"the :class:`str() <str>` of the mixed-in type."
210210
msgstr ""
211211
"由 :class:`IntEnum`、:class:`StrEnum` 及 :class:`IntFlag` 所使用來保留這些混"
212-
"合類型的 :class:`str() <str>`。"
212+
"合型別的 :class:`str() <str>`。"
213213

214214
#: ../../library/enum.rst:101
215215
msgid ":class:`EnumCheck`"
@@ -419,7 +419,7 @@ msgstr "type"
419419

420420
#: ../../library/enum.rst:190
421421
msgid "A mix-in type for the new Enum."
422-
msgstr "新列舉的混合類型。"
422+
msgstr "新列舉的混合型別。"
423423

424424
#: ../../library/enum.rst:0
425425
msgid "start"
@@ -615,7 +615,7 @@ msgid ""
615615
msgstr ""
616616
"雖然可以使用可變的 (mutable) / 不可雜湊的 (unhashable) 值,例如 :class:"
617617
"`dict`、:class:`list` 或可變的 :class:`~dataclasses.dataclass`,它們在建立期"
618-
"間會對效能產生相對於列舉中可變的 / 不可雜湊的值的總數量的二次方的影響。"
618+
"間會對效能產生相對於列舉中可變的 / 不可雜湊的值總數量的二次方影響。"
619619

620620
#: ../../library/enum.rst:298
621621
msgid "Name of the member."
@@ -1259,7 +1259,7 @@ msgid ""
12591259
"but the :class:`str() <str>` of the mixed-in data type:"
12601260
msgstr ""
12611261
":class:`!ReprEnum` 使用 :class:`Enum` 的 :meth:`repr() <Enum.__repr__>`,但使"
1262-
"用混合資料類型的 :class:`str() <str>`:"
1262+
"用混合資料型別的 :class:`str() <str>`:"
12631263

12641264
#: ../../library/enum.rst:691
12651265
msgid ":meth:`!int.__str__` for :class:`IntEnum` and :class:`IntFlag`"
@@ -1275,7 +1275,7 @@ msgid ""
12751275
"`format` of the mixed-in data type instead of using the :class:`Enum`-"
12761276
"default :meth:`str() <Enum.__str__>`."
12771277
msgstr ""
1278-
"繼承 :class:`!ReprEnum` 來保留混合資料類型的 :class:`str() <str>` / :func:"
1278+
"繼承 :class:`!ReprEnum` 來保留混合資料型別的 :class:`str() <str>` / :func:"
12791279
"`format`,而不是使用 :class:`Enum` 預設的 :meth:`str() <Enum.__str__>`。"
12801280

12811281
#: ../../library/enum.rst:703
@@ -1665,7 +1665,7 @@ msgid ""
16651665
"incompatible type."
16661666
msgstr ""
16671667
"在 3.13 預設 ``_generate_next_value_`` 總是回傳最大的成員值加一,如果任何成員"
1668-
"是不相容的類型就會失敗。"
1668+
"是不相容的型別就會失敗。"
16691669

16701670
#: ../../library/enum.rst:913
16711671
msgid ""
@@ -1767,7 +1767,7 @@ msgid ""
17671767
"These three enum types are designed to be drop-in replacements for existing "
17681768
"integer- and string-based values; as such, they have extra limitations:"
17691769
msgstr ""
1770-
"這三種列舉類型是設計來直接取代現有以整數及字串為基底的值;因此它們有額外的限"
1770+
"這三種列舉型別是設計來直接取代現有以整數及字串為基底的值;因此它們有額外的限"
17711771
"制:"
17721772

17731773
#: ../../library/enum.rst:988
@@ -1785,7 +1785,7 @@ msgid ""
17851785
"If you do not need/want those limitations, you can either create your own "
17861786
"base class by mixing in the ``int`` or ``str`` type yourself::"
17871787
msgstr ""
1788-
"如果你不需要或不想要這些限制,你可以透過混合 ``int`` 或 ``str`` 類型來建立自"
1788+
"如果你不需要或不想要這些限制,你可以透過混合 ``int`` 或 ``str`` 型別來建立自"
17891789
"己的基礎類別: ::"
17901790

17911791
#: ../../library/enum.rst:996

library/exceptions.po

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ msgid ""
162162
"possible conflicts between how the bases handle the ``args`` attribute, as "
163163
"well as due to possible memory layout incompatibilities."
164164
msgstr ""
165-
"使用者的程式碼可以建立繼承自例外類型的子類別。建議一次只繼承一種例外類型以避"
165+
"使用者的程式碼可以建立繼承自例外型別的子類別。建議一次只繼承一種例外型別以避"
166166
"免在基底類別之間如何處理 ``args`` 屬性的任何可能衝突,以及可能的記憶體佈局 "
167167
"(memory layout) 不相容。"
168168

@@ -176,9 +176,9 @@ msgid ""
176176
"it's recommended to avoid subclassing multiple exception types altogether."
177177
msgstr ""
178178
"為了效率,大部分的內建例外使用 C 來實作,參考 :source:`Objects/exceptions."
179-
"c`。一些例外有客製化的記憶體佈局,使其不可能建立一個繼承多種例外類型的子類"
180-
"別。類型的記憶體佈局是實作細節且可能會在不同 Python 版本間改變,造成未來新的"
181-
"衝突。因此,總之建議避免繼承多種例外類型。"
179+
"c`。一些例外有客製化的記憶體佈局,使其不可能建立一個繼承多種例外型別的子類"
180+
"別。型別的記憶體佈局是實作細節且可能會在不同 Python 版本間改變,造成未來新的"
181+
"衝突。因此,總之建議避免繼承多種例外型別。"
182182

183183
#: ../../library/exceptions.rst:105
184184
msgid "Base classes"
@@ -879,7 +879,7 @@ msgstr ""
879879
"可以正確地向上傳遞並導致直譯器結束。當它未被處理時,Python 直譯器會結束;不會"
880880
"印出堆疊回溯。建構函式接受跟傳入 :func:`sys.exit` 一樣的可選引數。如果該值是"
881881
"整數,它會指定系統的結束狀態(傳入 C 的 :c:func:`exit` 函式 );如果它是 "
882-
"``None``,結束狀態會是 0;如果它是其他類型(例如字串),則物件的值會被印出而"
882+
"``None``,結束狀態會是 0;如果它是其他型別(例如字串),則物件的值會被印出而"
883883
"結束狀態是 1。"
884884

885885
#: ../../library/exceptions.rst:587
@@ -908,8 +908,8 @@ msgid ""
908908
"inappropriate type. The associated value is a string giving details about "
909909
"the type mismatch."
910910
msgstr ""
911-
"當一個操作或函式被用在不適合的類型的物件時會引發此例外。關聯值是一個字串,提"
912-
"供關於不相符類型的細節。"
911+
"當一個操作或函式被用在不適合的型別的物件時會引發此例外。關聯值是一個字串,提"
912+
"供關於不相符型別的細節。"
913913

914914
#: ../../library/exceptions.rst:605
915915
msgid ""
@@ -929,7 +929,7 @@ msgid ""
929929
"arguments with the wrong value (e.g. a number outside expected boundaries) "
930930
"should result in a :exc:`ValueError`."
931931
msgstr ""
932-
"傳入錯誤類型的引數(例如當預期傳入 :class:`int` 卻傳入 :class:`list`)應該要"
932+
"傳入錯誤型別的引數(例如當預期傳入 :class:`int` 卻傳入 :class:`list`)應該要"
933933
"導致 :exc:`TypeError`,但傳入帶有錯誤值的引數(例如超出預期範圍的數值)應該要"
934934
"導致 :exc:`ValueError`。"
935935

@@ -1009,7 +1009,7 @@ msgid ""
10091009
"type but an inappropriate value, and the situation is not described by a "
10101010
"more precise exception such as :exc:`IndexError`."
10111011
msgstr ""
1012-
"當一個操作或函式收到引數是正確類型但是不適合的值,且該情況無法被更精確的例外"
1012+
"當一個操作或函式收到引數是正確型別但是不適合的值,且該情況無法被更精確的例外"
10131013
"例如 :exc:`IndexError` 所描述時會引發此例外。"
10141014

10151015
#: ../../library/exceptions.rst:679
@@ -1338,7 +1338,7 @@ msgid ""
13381338
"based on the types of the contained exceptions."
13391339
msgstr ""
13401340
"當需要引發多個不相關例外時會使用下列的類別。它們是例外階層的一部分所以可以像"
1341-
"所有其他例外一樣使用 :keyword:`except` 來處理。此外,它們會以包含的例外類型為"
1341+
"所有其他例外一樣使用 :keyword:`except` 來處理。此外,它們會以包含的例外型別為"
13421342
"基礎來比對其子群組而被 :keyword:`except*<except_star>` 辨認出來。"
13431343

13441344
#: ../../library/exceptions.rst:932
@@ -1351,7 +1351,7 @@ msgid ""
13511351
"is so that ``except Exception`` catches an :exc:`ExceptionGroup` but not :"
13521352
"exc:`BaseExceptionGroup`."
13531353
msgstr ""
1354-
"這兩個例外類型都將例外包裝在序列 ``excs`` 中。``msg`` 參數必須是字串。這兩個"
1354+
"這兩個例外型別都將例外包裝在序列 ``excs`` 中。``msg`` 參數必須是字串。這兩個"
13551355
"類別的差異是 :exc:`BaseExceptionGroup` 擴充了 :exc:`BaseException` 且可以包裝"
13561356
"任何例外,而 :exc:`ExceptionGroup` 擴充了 :exc:`Exception` 且只能包裝 :exc:"
13571357
"`Exception` 的子類別。這個設計使得 ``except Exception`` 可以捕捉 :exc:"
@@ -1396,9 +1396,9 @@ msgid ""
13961396
"type object) that accepts an exception as its single argument and returns "
13971397
"true for the exceptions that should be in the subgroup."
13981398
msgstr ""
1399-
"條件式可以是一個例外類型或是例外類型的元組,在此情況下,每個例外都會使用與 "
1399+
"條件式可以是一個例外型別或是例外型別的元組,在此情況下,每個例外都會使用與 "
14001400
"``except`` 子句中使用的相同檢查方法來檢查是否有匹配。條件式也可以是一個可呼叫"
1401-
"物件(除了類型物件之外),其接受一個例外作為單一引數,而如果該例外應該在子群"
1401+
"物件(除了型別物件之外),其接受一個例外作為單一引數,而如果該例外應該在子群"
14021402
"組中就回傳 true。"
14031403

14041404
#: ../../library/exceptions.rst:967
@@ -1425,7 +1425,7 @@ msgstr ""
14251425

14261426
#: ../../library/exceptions.rst:978
14271427
msgid "``condition`` can be any callable which is not a type object."
1428-
msgstr "``condition`` 可以是任何不是類型物件的可呼叫物件。"
1428+
msgstr "``condition`` 可以是任何不是型別物件的可呼叫物件。"
14291429

14301430
#: ../../library/exceptions.rst:983
14311431
msgid ""

0 commit comments

Comments
 (0)
0