Skip to content

Sync with CPython 3.11 #396

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Feb 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions c-api/dict.po
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Python 3.11\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2022-10-06 00:23+0000\n"
"POT-Creation-Date: 2023-02-15 00:17+0000\n"
"PO-Revision-Date: 2017-09-22 18:26+0000\n"
"Last-Translator: Liang-Bo Wang <me@liang2.tw>\n"
"Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
Expand Down Expand Up @@ -98,9 +98,10 @@ msgstr ""

#: ../../c-api/dict.rst:83
msgid ""
"Remove the entry in dictionary *p* with key *key*. *key* must be hashable; "
"if it isn't, :exc:`TypeError` is raised. If *key* is not in the dictionary, :"
"exc:`KeyError` is raised. Return ``0`` on success or ``-1`` on failure."
"Remove the entry in dictionary *p* with key *key*. *key* must be :term:"
"`hashable`; if it isn't, :exc:`TypeError` is raised. If *key* is not in the "
"dictionary, :exc:`KeyError` is raised. Return ``0`` on success or ``-1`` on "
"failure."
msgstr ""

#: ../../c-api/dict.rst:91
Expand Down
16 changes: 8 additions & 8 deletions c-api/module.po
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Python 3.11\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2022-10-06 00:23+0000\n"
"POT-Creation-Date: 2023-02-18 00:17+0000\n"
"PO-Revision-Date: 2018-05-23 14:32+0000\n"
"Last-Translator: Adrian Liaw <adrianliaw2000@gmail.com>\n"
"Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
Expand Down Expand Up @@ -444,17 +444,17 @@ msgstr ""

#: ../../c-api/module.rst:391
msgid ""
"Create a new module object, given the definition in *module* and the "
"ModuleSpec *spec*. This behaves like :c:func:`PyModule_FromDefAndSpec2` "
"with *module_api_version* set to :const:`PYTHON_API_VERSION`."
"Create a new module object, given the definition in *def* and the ModuleSpec "
"*spec*. This behaves like :c:func:`PyModule_FromDefAndSpec2` with "
"*module_api_version* set to :const:`PYTHON_API_VERSION`."
msgstr ""

#: ../../c-api/module.rst:399
msgid ""
"Create a new module object, given the definition in *module* and the "
"ModuleSpec *spec*, assuming the API version *module_api_version*. If that "
"version does not match the version of the running interpreter, a :exc:"
"`RuntimeWarning` is emitted."
"Create a new module object, given the definition in *def* and the ModuleSpec "
"*spec*, assuming the API version *module_api_version*. If that version does "
"not match the version of the running interpreter, a :exc:`RuntimeWarning` is "
"emitted."
msgstr ""

#: ../../c-api/module.rst:406
Expand Down
6 changes: 3 additions & 3 deletions c-api/object.po
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Python 3.11\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2022-10-15 20:43+0000\n"
"POT-Creation-Date: 2023-02-15 00:17+0000\n"
"PO-Revision-Date: 2018-05-23 14:32+0000\n"
"Last-Translator: Adrian Liaw <adrianliaw2000@gmail.com>\n"
"Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
Expand Down Expand Up @@ -301,8 +301,8 @@ msgstr ""

#: ../../c-api/object.rst:284
msgid ""
"Set a :exc:`TypeError` indicating that ``type(o)`` is not hashable and "
"return ``-1``. This function receives special treatment when stored in a "
"Set a :exc:`TypeError` indicating that ``type(o)`` is not :term:`hashable` "
"and return ``-1``. This function receives special treatment when stored in a "
"``tp_hash`` slot, allowing a type to explicitly indicate to the interpreter "
"that it is not hashable."
msgstr ""
Expand Down
15 changes: 7 additions & 8 deletions faq/programming.po
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ msgid ""
msgstr ""
"Project-Id-Version: Python 3.11\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2022-12-29 00:16+0000\n"
"PO-Revision-Date: 2023-02-18 13:52+0800\n"
"POT-Creation-Date: 2023-02-15 00:17+0000\n"
"PO-Revision-Date: 2023-02-18 14:48+0800\n"
"Last-Translator: Adrian Liaw <adrianliaw2000@gmail.com>\n"
"Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
"tw)\n"
Expand Down Expand Up @@ -3031,14 +3031,13 @@ msgstr ""
"積的方法結果也會累積。他們可以不受限制地成長。"

#: ../../faq/programming.rst:1982
#, fuzzy
msgid ""
"The *lru_cache* approach works with methods that have hashable arguments. "
"It creates a reference to the instance unless special efforts are made to "
"pass in weak references."
"The *lru_cache* approach works with methods that have :term:`hashable` "
"arguments. It creates a reference to the instance unless special efforts "
"are made to pass in weak references."
msgstr ""
"*lru_cache* 方法適用於具有可散列引數的方法。除非特別努力傳遞弱引用,否則它會"
"建立對實例的引用。"
"*lru_cache* 方法適用於具有\\ :term:`可雜湊 <hashable>`\\ 引數的方法。除非特別"
"努力傳遞弱引用,否則它會建立對實例的引用。"

#: ../../faq/programming.rst:1986
#, fuzzy
Expand Down
6 changes: 3 additions & 3 deletions library/abc.po
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Python 3.11\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-10-26 16:47+0000\n"
"POT-Creation-Date: 2023-02-15 00:17+0000\n"
"PO-Revision-Date: 2018-05-23 14:38+0000\n"
"Last-Translator: Adrian Liaw <adrianliaw2000@gmail.com>\n"
"Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
Expand Down Expand Up @@ -39,8 +39,8 @@ msgid ""
"The :mod:`collections` module has some concrete classes that derive from "
"ABCs; these can, of course, be further derived. In addition, the :mod:"
"`collections.abc` submodule has some ABCs that can be used to test whether a "
"class or instance provides a particular interface, for example, if it is "
"hashable or if it is a mapping."
"class or instance provides a particular interface, for example, if it is :"
"term:`hashable` or if it is a mapping."
msgstr ""

#: ../../library/abc.rst:27
Expand Down
14 changes: 7 additions & 7 deletions library/collections.abc.po
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Python 3.11\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2022-10-15 20:43+0000\n"
"POT-Creation-Date: 2023-02-15 00:17+0000\n"
"PO-Revision-Date: 2018-05-23 14:41+0000\n"
"Last-Translator: Adrian Liaw <adrianliaw2000@gmail.com>\n"
"Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
Expand All @@ -34,7 +34,7 @@ msgstr "**原始碼:**\\ :source:`Lib/_collections_abc.py`"
msgid ""
"This module provides :term:`abstract base classes <abstract base class>` "
"that can be used to test whether a class provides a particular interface; "
"for example, whether it is hashable or whether it is a mapping."
"for example, whether it is :term:`hashable` or whether it is a mapping."
msgstr ""

#: ../../library/collections.abc.rst:27
Expand Down Expand Up @@ -275,8 +275,8 @@ msgstr ":class:`MutableSet`"
#: ../../library/collections.abc.rst:151
msgid "``__contains__``, ``__iter__``, ``__len__``, ``add``, ``discard``"
msgstr ""
"``__contains__``\\ 、\\ ``__iter__``\\ 、\\ ``__len__``\\ 、\\ ``add``"
"\\ 、\\ ``discard``"
"``__contains__``\\ 、\\ ``__iter__``\\ 、\\ ``__len__``\\ 、\\ "
"``add``\\ 、\\ ``discard``"

#: ../../library/collections.abc.rst:151
msgid ""
Expand Down Expand Up @@ -620,9 +620,9 @@ msgstr ""
msgid ""
"The :class:`Set` mixin provides a :meth:`_hash` method to compute a hash "
"value for the set; however, :meth:`__hash__` is not defined because not all "
"sets are hashable or immutable. To add set hashability using mixins, "
"inherit from both :meth:`Set` and :meth:`Hashable`, then define ``__hash__ = "
"Set._hash``."
"sets are :term:`hashable` or immutable. To add set hashability using "
"mixins, inherit from both :meth:`Set` and :meth:`Hashable`, then define "
"``__hash__ = Set._hash``."
msgstr ""

#: ../../library/collections.abc.rst:415
Expand Down
38 changes: 20 additions & 18 deletions library/collections.po
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ msgid ""
msgstr ""
"Project-Id-Version: Python 3.11\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2022-02-26 00:11+0000\n"
"PO-Revision-Date: 2022-03-01 01:14+0800\n"
"POT-Creation-Date: 2023-02-15 00:17+0000\n"
"PO-Revision-Date: 2023-02-18 14:48+0800\n"
"Last-Translator: Matt Wang <mattwang44@gmail.com>\n"
"Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
"tw)\n"
Expand All @@ -20,7 +20,7 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=1; plural=0;\n"
"X-Generator: Poedit 3.0.1\n"
"X-Generator: Poedit 3.2.2\n"

#: ../../library/collections.rst:2
msgid ":mod:`collections` --- Container datatypes"
Expand Down Expand Up @@ -70,8 +70,8 @@ msgid ":class:`Counter`"
msgstr ":class:`Counter`"

#: ../../library/collections.rst:28
msgid "dict subclass for counting hashable objects"
msgstr "dict 的子類別,用來計算可雜湊 (hashable) 物件的數量"
msgid "dict subclass for counting :term:`hashable` objects"
msgstr "dict 的子類別,用來計算\\ :term:`可雜湊 <hashable>`\\ 物件的數量"

#: ../../library/collections.rst:29
msgid ":class:`OrderedDict`"
Expand Down Expand Up @@ -225,9 +225,9 @@ msgid ""
"reference to ``d.parents`` is equivalent to: ``ChainMap(*d.maps[1:])``."
msgstr ""
"回傳一個包含除了第一個以外所有其他對映的新 :class:`ChainMap` 的特性,可用於需"
"要跳過第一個對映的搜索。使用情境類似於在\\ :term:`巢狀作用域 <nested scope>`"
"\\ 當中使用 :keyword:`nonlocal` 關鍵字,也可與內建函式 :func:`super` 做類比。"
"引用 ``d.parents`` 等同於 ``ChainMap(*d.maps[1:])``。"
"要跳過第一個對映的搜索。使用情境類似於在\\ :term:`巢狀作用域 <nested "
"scope>`\\ 當中使用 :keyword:`nonlocal` 關鍵字,也可與內建函式 :func:`super` "
"做類比。引用 ``d.parents`` 等同於 ``ChainMap(*d.maps[1:])``。"

#: ../../library/collections.rst:102
msgid ""
Expand Down Expand Up @@ -353,15 +353,16 @@ msgstr ""

#: ../../library/collections.rst:244
msgid ""
"A :class:`Counter` is a :class:`dict` subclass for counting hashable "
"A :class:`Counter` is a :class:`dict` subclass for counting :term:`hashable` "
"objects. It is a collection where elements are stored as dictionary keys and "
"their counts are stored as dictionary values. Counts are allowed to be any "
"integer value including zero or negative counts. The :class:`Counter` class "
"is similar to bags or multisets in other languages."
msgstr ""
":class:`Counter` 是 :class:`dict` 的子類別,用來計算可雜湊物件的數量。它是將"
"物件與其計數作為字典的鍵值對儲存的集合容器。計數可以是包含 0 與負數的任何整數"
"值。:class:`Counter` 類別類似其他程式語言中的 bags 或 multisets。"
":class:`Counter` 是 :class:`dict` 的子類別,用來計算\\ :term:`可雜湊 "
"<hashable>`\\ 物件的數量。它是將物件與其計數作為字典的鍵值對儲存的集合容器。"
"計數可以是包含 0 與負數的任何整數值。:class:`Counter` 類別類似其他程式語言中"
"的 bags 或 multisets。"

#: ../../library/collections.rst:250
msgid ""
Expand Down Expand Up @@ -839,10 +840,11 @@ msgid ""
"popleft`; otherwise, it can be cycled back to the end with the :meth:`~deque."
"rotate` method::"
msgstr ""
"一個\\ `輪詢調度器 <https://en.wikipedia.org/wiki/Round-robin_scheduling>`_"
"\\ 可以透過在 :class:`deque` 中放入 iterator 來實現,值自當前 iterator 的位"
"置 0 取出,如果 iterator 已經消耗完畢就用 :meth:`~deque.popleft` 將其從佇列中"
"移除,否則利用 :meth:`~deque.rotate` 來將其移至佇列尾端:\n"
"一個\\ `輪詢調度器 <https://en.wikipedia.org/wiki/Round-"
"robin_scheduling>`_\\ 可以透過在 :class:`deque` 中放入 iterator 來實現,值自"
"當前 iterator 的位置 0 取出,如果 iterator 已經消耗完畢就用 :meth:`~deque."
"popleft` 將其從佇列中移除,否則利用 :meth:`~deque.rotate` 來將其移至佇列尾"
"端:\n"
"\n"
"::"

Expand Down Expand Up @@ -1474,8 +1476,8 @@ msgid ""
"The items, keys, and values :term:`views <dictionary view>` of :class:"
"`OrderedDict` now support reverse iteration using :func:`reversed`."
msgstr ""
":class:`OrderedDict` 的項 (item)、鍵與值之\\ :term:`視圖 <dictionary view>`"
"\\ 現在可透過 :func:`reversed` 來倒序疊代。"
":class:`OrderedDict` 的項 (item)、鍵與值之\\ :term:`視圖 <dictionary "
"view>`\\ 現在可透過 :func:`reversed` 來倒序疊代。"

#: ../../library/collections.rst:1175
msgid ""
Expand Down
16 changes: 8 additions & 8 deletions library/configparser.po
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Python 3.11\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2022-10-31 08:13+0000\n"
"POT-Creation-Date: 2023-02-17 00:18+0000\n"
"PO-Revision-Date: 2018-05-23 14:41+0000\n"
"Last-Translator: Adrian Liaw <adrianliaw2000@gmail.com>\n"
"Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
Expand Down Expand Up @@ -167,7 +167,7 @@ msgid ""
"Please note that default values have precedence over fallback values. For "
"instance, in our example the ``'CompressionLevel'`` key was specified only "
"in the ``'DEFAULT'`` section. If we try to get it from the section "
"``'topsecret.server.com'``, we will always get the default, even if we "
"``'topsecret.server.example'``, we will always get the default, even if we "
"specify a fallback:"
msgstr ""

Expand Down Expand Up @@ -251,8 +251,8 @@ msgstr ""

#: ../../library/configparser.rst:364
msgid ""
"With ``interpolation`` set to ``None``, the parser would simply return ``"
"%(my_dir)s/Pictures`` as the value of ``my_pictures`` and ``%(home_dir)s/"
"With ``interpolation`` set to ``None``, the parser would simply return "
"``%(my_dir)s/Pictures`` as the value of ``my_pictures`` and ``%(home_dir)s/"
"lumberjack`` as the value of ``my_dir``."
msgstr ""

Expand Down Expand Up @@ -532,8 +532,8 @@ msgstr ""

#: ../../library/configparser.rst:669
msgid ""
"*default_section*, default value: ``configparser.DEFAULTSECT`` (that is: ``"
"\"DEFAULT\"``)"
"*default_section*, default value: ``configparser.DEFAULTSECT`` (that is: "
"``\"DEFAULT\"``)"
msgstr ""

#: ../../library/configparser.rst:672
Expand All @@ -542,8 +542,8 @@ msgid ""
"sections or interpolation purposes is a powerful concept of this library, "
"letting users create complex declarative configurations. This section is "
"normally called ``\"DEFAULT\"`` but this can be customized to point to any "
"other valid section name. Some typical values include: ``\"general\"`` or ``"
"\"common\"``. The name provided is used for recognizing default sections "
"other valid section name. Some typical values include: ``\"general\"`` or "
"``\"common\"``. The name provided is used for recognizing default sections "
"when reading from any source and is used when writing configuration back to "
"a file. Its current value can be retrieved using the ``parser_instance."
"default_section`` attribute and may be modified at runtime (i.e. to convert "
Expand Down
6 changes: 3 additions & 3 deletions library/datetime.po
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Python 3.11\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2023-01-21 00:16+0000\n"
"POT-Creation-Date: 2023-02-15 00:17+0000\n"
"PO-Revision-Date: 2018-05-23 14:42+0000\n"
"Last-Translator: Adrian Liaw <adrianliaw2000@gmail.com>\n"
"Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
Expand Down Expand Up @@ -210,8 +210,8 @@ msgstr ""

#: ../../library/datetime.rst:163
msgid ""
"Objects of these types are hashable, meaning that they can be used as "
"dictionary keys."
"Objects of these types are :term:`hashable`, meaning that they can be used "
"as dictionary keys."
msgstr ""

#: ../../library/datetime.rst:165
Expand Down
Loading