8000 Update translations from Transifex · python/python-docs-ja@10fb976 · GitHub
[go: up one dir, main page]

Skip to content

Commit 10fb976

Browse files
author
github-actions
committed
Update translations from Transifex
1 parent 5229e03 commit 10fb976

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

63 files changed

+20331
-19396
lines changed

c-api/allocation.po

Lines changed: 138 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -4,17 +4,16 @@
44
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
55
#
66
# Translators:
7-
# tomo, 2021
8-
# souma987, 2023
7+
# tomo, 2025
98
#
109
#, fuzzy
1110
msgid ""
1211
msgstr ""
1312
"Project-Id-Version: Python 3.14\n"
1413
"Report-Msgid-Bugs-To: \n"
15-
"POT-Creation-Date: 2025-05-08 02:53-0300\n"
14+
"POT-Creation-Date: 2025-05-23 14:20+0000\n"
1615
"PO-Revision-Date: 2021-06-28 00:47+0000\n"
17-
"Last-Translator: souma987, 2023\n"
16+
"Last-Translator: tomo, 2025\n"
1817
"Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/"
1918
"ja/)\n"
2019
"MIME-Version: 1.0\n"
@@ -31,74 +30,164 @@ msgstr "オブジェクトをヒープ上にメモリ確保する"
3130
msgid ""
3231
"Initialize a newly allocated object *op* with its type and initial "
3332
"reference. Returns the initialized object. Other fields of the object are "
34-
"not affected."
33+
"not initialized. Despite its name, this function is unrelated to the "
34+
"object's :meth:`~object.__init__` method (:c:member:`~PyTypeObject.tp_init` "
35+
"slot). Specifically, this function does **not** call the object's :meth:`!"
36+
"__init__` method."
3537
msgstr ""
3638

3739
#: ../../c-api/allocation.rst:24
3840
msgid ""
41+
"In general, consider this function to be a low-level routine. Use :c:member:"
42+
"`~PyTypeObject.tp_alloc` where possible. For implementing :c:member:`!"
43+
"tp_alloc` for your type, prefer :c:func:`PyType_GenericAlloc` or :c:func:"
44+
"`PyObject_New`."
45+
msgstr ""
46+
47+
#: ../../c-api/allocation.rst:31
48+
msgid ""
49+
"This function only initializes the object's memory corresponding to the "
50+
"initial :c:type:`PyObject` structure. It does not zero the rest."
51+
msgstr ""
52+
53+
#: ../../c-api/allocation.rst:37
54+
msgid ""
3955
"This does everything :c:func:`PyObject_Init` does, and also initializes the "
4056
"length information for a variable-size object."
4157
msgstr ""
4258
":c:func:`PyObject_Init` の全ての処理を行い、可変サイズオブジェクトの場合には"
4359
"長さ情報も初期化します。"
4460

45-
#: ../../c-api/allocation.rst:30
61+
#: ../../c-api/allocation.rst:42
62+
msgid ""
63+
"This function only initializes some of the object's memory. It does not "
64+
"zero the rest."
65+
msgstr ""
66+
67+
#: ../../c-api/allocation.rst:48
68+
msgid ""
69+
"Allocates a new Python object using the C structure type *TYPE* and the "
70+
"Python type object *typeobj* (``PyTypeObject*``) by calling :c:func:"
71+
"`PyObject_Malloc` to allocate memory and initializing it like :c:func:"
72+
"`PyObject_Init`. The caller will own the only reference to the object (i.e. "
73+
"its reference count will be one)."
74+
msgstr ""
75+
76+
#: ../../c-api/allocation.rst:54 ../../c-api/allocation.rst:107
77+
msgid ""
78+
"Avoid calling this directly to allocate memory for an object; call the "
79+
"type's :c:member:`~PyTypeObject.tp_alloc` slot instead."
80+
msgstr ""
81+
82+
#: ../../c-api/allocation.rst:57 ../../c-api/allocation.rst:110
83+
msgid ""
84+
"When populating a type's :c:member:`~PyTypeObject.tp_alloc` slot, :c:func:"
85+
"`PyType_GenericAlloc` is preferred over a custom function that simply calls "
86+
"this macro."
87+
msgstr ""
88+
89+
#: ../../c-api/allocation.rst:61
90+
msgid ""
91+
"This macro does not call :c:member:`~PyTypeObject.tp_alloc`, :c:member:"
92+
"`~PyTypeObject.tp_new` (:meth:`~object.__new__`), or :c:member:"
93+
"`~PyTypeObject.tp_init` (:meth:`~object.__init__`)."
94+
msgstr ""
95+
96+
#: ../../c-api/allocation.rst:65
97+
msgid ""
98+
"This cannot be used for objects with :c:macro:`Py_TPFLAGS_HAVE_GC` set in :c:"
99+
"member:`~PyTypeObject.tp_flags`; use :c:macro:`PyObject_GC_New` instead."
100+
msgstr ""
101+
102+
#: ../../c-api/allocation.rst:68
103+
msgid ""
104+
"Memory allocated by this macro must be freed with :c:func:`PyObject_Free` "
105+
"(usually called via the object's :c:member:`~PyTypeObject.tp_free` slot)."
106+
msgstr ""
107+
108+
#: ../../c-api/allocation.rst:73 ../../c-api/allocation.rst:123
46109
msgid ""
47-
"Allocate a new Python object using the C structure type *TYPE* and the "
48-
"Python type object *typeobj* (``PyTypeObject*``). Fields not defined by the "
49-
"Python object header are not initialized. The caller will own the only "
50-
"reference to the object (i.e. its reference count will be one). The size of "
51-
"the memory allocation is determined from the :c:member:`~PyTypeObject."
52-
"tp_basicsize` field of the type object."
110+
"The returned memory is not guaranteed to have been completely zeroed before "
111+
"it was initialized."
53112
msgstr ""
54-
"C の構造体型 *TYPE* と Python の型オブジェクト *typeobj* "
55-
"( ``PyTypeObject*`` ) を用いて Python オブジェクトの領域を新規確保します。"
56-
"Python のオブジェクトヘッダに定義されていないフィールドは初期化されません。呼"
57-
"び出し元がオブジェクトへの唯一の参照を持ちます(つまり、参照カウントは1にな"
58-
"ります)。メモリ割り当ての大きさは型オブジェクトの :c:member:`~PyTypeObject."
59-
"tp_basicsize` フィールドによって定められます。"
60113

61-
#: ../../c-api/allocation.rst:38
114+
#: ../../c-api/allocation.rst:78 ../../c-api/allocation.rst:128
62115
msgid ""
63-
"Note that this function is unsuitable if *typeobj* has :c:macro:"
64 EED3 -
"`Py_TPFLAGS_HAVE_GC` set. For such objects, use :c:func:`PyObject_GC_New` "
65-
"instead."
116+
"This macro does not construct a fully initialized object of the given type; "
117+
"it merely allocates memory and prepares it for further initialization by :c:"
118+
"member:`~PyTypeObject.tp_init`. To construct a fully initialized object, "
119+
"call *typeobj* instead. For example::"
120+
msgstr ""
121+
122+
#: ../../c-api/allocation.rst:83
123+
msgid "PyObject *foo = PyObject_CallNoArgs((PyObject *)&PyFoo_Type);"
124+
msgstr ""
125+
126+
#: ../../c-api/allocation.rst:87 ../../c-api/allocation.rst:137
127+
msgid ":c:func:`PyObject_Free`"
128+
msgstr ":c:func:`PyObject_Free`"
129+
130+
#: ../../c-api/allocation.rst:88
131+
msgid ":c:macro:`PyObject_GC_New`"
66132
msgstr ""
67133

68-
#: ../../c-api/allocation.rst:45
134+
#: ../../c-api/allocation.rst:89 ../../c-api/allocation.rst:139
135+
msgid ":c:func:`PyType_GenericAlloc`"
136+
msgstr ""
137+
138+
#: ../../c-api/allocation.rst:90 ../../c-api/allocation.rst:140
139+
msgid ":c:member:`~PyTypeObject.tp_alloc`"
140+
msgstr ":c:member:`~PyTypeObject.tp_alloc`"
141+
142+
#: ../../c-api/allocation.rst:95
143+
msgid "Like :c:macro:`PyObject_New` except:"
144+
msgstr ""
145+
146+
#: ../../c-api/allocation.rst:97
69147
msgid ""
70-
"Allocate a new Python object using the C structure type *TYPE* and the "
71-
"Python type object *typeobj* (``PyTypeObject*``). Fields not defined by the "
72-
"Python object header are not initialized. The allocated memory allows for "
73-
"the *TYPE* structure plus *size* (``Py_ssize_t``) fields of the size given "
74-
"by the :c:member:`~PyTypeObject.tp_itemsize` field of *typeobj*. This is "
75-
"useful for implementing objects like tuples, which are able to determine "
76-
"their size at construction time. Embedding the array of fields into the "
77-
"same allocation decreases the number of allocations, improving the memory "
78-
"management efficiency."
148+
"It allocates enough memory for the *TYPE* structure plus *size* "
149+
"(``Py_ssize_t``) fields of the size given by the :c:member:`~PyTypeObject."
150+
"tp_itemsize` field of *typeobj*."
79151
msgstr ""
80-
"C の構造体型 *TYPE* と Python の型オブジェクト *typeobj* "
81-
"( ``PyTypeObject*`` ) を用いて Python オブジェクトの領域を新規確保します。"
82-
"Python のオブジェクトヘッダに定義されていないフィールドは初期化されません。確"
83-
"保されたメモリには、 *TYPE* 構造体に加え、 *typeobj* の :c:member:"
84-
"`~PyTypeObject.tp_itemsize` フィールドによって定められた大きさのフィールドを "
85-
"*size* ( ``Py_ssize_t`` ) 個分格納できます。これはタプルなどの、生成時に大き"
86-
"さを決定できるオブジェクトを実装する際に便利です。同じメモリ割当にフィールド"
87-
"の配列も埋め込むことで、メモリ割当の回数を減らし、メモリ管理効率を上げること"
88-
"ができます。"
89152

90-
#: ../../c-api/allocation.rst:56
153+
#: ../../c-api/allocation.rst:100
154+
msgid "The memory is initialized like :c:func:`PyObject_InitVar`."
155+
msgstr ""
156+
157+
#: ../../c-api/allocation.rst:102
158+
msgid ""
159+
"This is useful for implementing objects like tuples, which are able to "
160+
"determine their size at construction time. Embedding the array of fields "
161+
"into the same allocation decreases the number of allocations, improving the "
162+
"memory management efficiency."
163+
msgstr ""
164+
165+
#: ../../c-api/allocation.rst:114
166+
msgid ""
167+
"This cannot be used for objects with :c:macro:`Py_TPFLAGS_HAVE_GC` set in :c:"
168+
"member:`~PyTypeObject.tp_flags`; use :c:macro:`PyObject_GC_NewVar` instead."
169+
msgstr ""
170+
171+
#: ../../c-api/allocation.rst:118
172+
msgid ""
173+
"Memory allocated by this function must be freed with :c:func:`PyObject_Free` "
174+
"(usually called via the object's :c:member:`~PyTypeObject.tp_free` slot)."
175+
msgstr ""
176+
177+
#: ../../c-api/allocation.rst:133
91178
msgid ""
92-
"Note that this function is unsuitable if *typeobj* has :c:macro:"
93-
"`Py_TPFLAGS_HAVE_GC` set. For such objects, use :c:func:`PyObject_GC_NewVar` "
94-
"instead."
179+
"PyObject *list_instance = PyObject_CallNoArgs((PyObject *)&PyList_Type);"
180+
msgstr ""
181+
182+
#: ../../c-api/allocation.rst:138
183+
msgid ":c:macro:`PyObject_GC_NewVar`"
95184
msgstr ""
96185

97-
#: ../../c-api/allocation.rst:63
186+
#: ../../c-api/allocation.rst:145
98187
msgid "Same as :c:func:`PyObject_Free`."
99188
msgstr ""
100189

101-
#: ../../c-api/allocation.rst:67
190+
#: ../../c-api/allocation.rst:149
102191
msgid ""
103192
"Object which is visible in Python as ``None``. This should only be accessed "
104193
"using the :c:macro:`Py_None` macro, which evaluates to a pointer to this "
@@ -108,10 +197,10 @@ msgstr ""
108197
"ブジェクトへのポインタを評価する :c:macro:`Py_None` マクロを使わなければなり"
109198
"ません。"
110199

111-
#: ../../c-api/allocation.rst:74
200+
#: ../../c-api/allocation.rst:156
112201
msgid ":c:func:`PyModule_Create`"
113202
msgstr ":c:func:`PyModule_Create`"
114203

115-
#: ../../c-api/allocation.rst:75
204+
#: ../../c-api/allocation.rst:157
116205
msgid "To allocate and create extension modules."
117206
msgstr "拡張モジュールのアロケートと生成。"

0 commit comments

Comments
 (0)
0