Skip to content
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

Sync with CPython 3.13 #990

Merged
merged 18 commits into from
Nov 10, 2024
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
30 changes: 13 additions & 17 deletions c-api/allocation.po
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) 2001-2022, Python Software Foundation
# Copyright (C) 2001-2024, Python Software Foundation
# This file is distributed under the same license as the Python package.
#
# Translators:
Expand All @@ -10,7 +9,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Python 3.13\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2023-08-09 00:03+0000\n"
"POT-Creation-Date: 2024-11-06 00:13+0000\n"
"PO-Revision-Date: 2022-10-16 15:35+0800\n"
"Last-Translator: Matt Wang <mattwang44@gmail.com>\n"
"Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
Expand All @@ -29,24 +28,21 @@ msgstr "在 heap 上分配物件"
#: ../../c-api/allocation.rst:17
msgid ""
"Initialize a newly allocated object *op* with its type and initial "
"reference. Returns the initialized object. If *type* indicates that the "
"object participates in the cyclic garbage detector, it is added to the "
"detector's set of observed objects. Other fields of the object are not "
"affected."
"reference. Returns the initialized object. Other fields of the object are "
"not affected."
msgstr ""
"用它的型別和初始參照來初始化新分配物件 *op*。已初始化的物件會被回傳。如果 "
"*type* 表示了該物件參與迴圈垃圾檢查器,則將其新增到檢查器的觀察物件集合中。物"
"件的其他欄位不受影響。"
"用它的型別和初始參照來初始化新分配物件 *op*。已初始化的物件會被回傳。物件的其"
"他欄位不受影響。"

#: ../../c-api/allocation.rst:26
#: ../../c-api/allocation.rst:24
msgid ""
"This does everything :c:func:`PyObject_Init` does, and also initializes the "
"length information for a variable-size object."
msgstr ""
"它會做到 :c:func:`PyObject_Init` 的所有功能,並且會初始化一個大小可變物件的長"
"度資訊。"

#: ../../c-api/allocation.rst:32
#: ../../c-api/allocation.rst:30
msgid ""
"Allocate a new Python object using the C structure type *TYPE* and the "
"Python type object *typeobj* (``PyTypeObject*``). Fields not defined by the "
Expand All @@ -60,7 +56,7 @@ msgstr ""
"化;呼叫者會擁有那個對於物件的唯一參照(物件的參照計數為一)。記憶體分配大小"
"由 type 物件的 :c:member:`~PyTypeObject.tp_basicsize` 欄位來指定。"

#: ../../c-api/allocation.rst:43
#: ../../c-api/allocation.rst:41
msgid ""
"Allocate a new Python object using the C structure type *TYPE* and the "
"Python type object *typeobj* (``PyTypeObject*``). Fields not defined by the "
Expand All @@ -79,7 +75,7 @@ msgstr ""
"於實現如 tuple 這種能夠在建立期間決定自己大小的物件是很實用的。將欄位的陣列嵌"
"入到相同的記憶體分配中可以減少記憶體分配的次數,這提高了記憶體管理的效率。"

#: ../../c-api/allocation.rst:57
#: ../../c-api/allocation.rst:55
msgid ""
"Releases memory allocated to an object using :c:macro:`PyObject_New` or :c:"
"macro:`PyObject_NewVar`. This is normally called from the :c:member:"
Expand All @@ -92,7 +88,7 @@ msgstr ""
"handler 中呼叫。呼叫這個函式以後,物件的各欄位都不可以被存取,因為原本分配的"
"記憶體已不再是一個有效的 Python 物件。"

#: ../../c-api/allocation.rst:66
#: ../../c-api/allocation.rst:64
msgid ""
"Object which is visible in Python as ``None``. This should only be accessed "
"using the :c:macro:`Py_None` macro, which evaluates to a pointer to this "
Expand All @@ -101,10 +97,10 @@ msgstr ""
"這個物件像是 Python 中的 ``None``。它只應該透過 :c:macro:`Py_None` 巨集來存"
"取,該巨集的拿到指向該物件的指標。"

#: ../../c-api/allocation.rst:73
#: ../../c-api/allocation.rst:71
msgid ":c:func:`PyModule_Create`"
msgstr ":c:func:`PyModule_Create`"

#: ../../c-api/allocation.rst:74
#: ../../c-api/allocation.rst:72
msgid "To allocate and create extension modules."
msgstr "分配記憶體和建立擴充模組。"
2 changes: 1 addition & 1 deletion c-api/arg.po
Original file line number Diff line number Diff line change
Expand Up @@ -820,7 +820,7 @@ msgstr ""

#: ../../c-api/arg.rst:465
msgid "Example::"
msgstr ""
msgstr "舉例來說: ::"

#: ../../c-api/arg.rst:467
msgid ""
Expand Down
Loading