66# Translators:
77# haaritsubaki, 2023
88# Waldemar Stoczkowski, 2023
9+ # Stan Ulbrych, 2025
910#
1011#, fuzzy
1112msgid ""
1213msgstr ""
1314"Project-Id-Version : Python 3.14\n "
1415"Report-Msgid-Bugs-To : \n "
15- "POT-Creation-Date : 2025-05-08 02:53-0300 \n "
16+ "POT-Creation-Date : 2025-05-23 14:20+0000 \n "
1617"PO-Revision-Date : 2021-06-28 00:47+0000\n "
17- "Last-Translator : Waldemar Stoczkowski, 2023 \n "
18+ "Last-Translator : Stan Ulbrych, 2025 \n "
1819"Language-Team : Polish (https://app.transifex.com/python-doc/teams/5390/pl/)\n "
1920"MIME-Version : 1.0\n "
2021"Content-Type : text/plain; charset=UTF-8\n "
@@ -30,7 +31,22 @@ msgstr "Przydzielanie obiektów na stercie"
3031msgid ""
3132"Initialize a newly allocated object *op* with its type and initial "
3233"reference. Returns the initialized object. Other fields of the object are "
33- "not affected."
34+ "not initialized. Despite its name, this function is unrelated to the "
35+ "object's :meth:`~object.__init__` method (:c:member:`~PyTypeObject.tp_init` "
36+ "slot). Specifically, this function does **not** call the object's :meth:`!"
37+ "__init__` method."
38+ msgstr ""
39+
40+ 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+ msgid ""
48+ "This function only initializes the object's memory corresponding to the "
49+ "initial :c:type:`PyObject` structure. It does not zero the rest."
3450msgstr ""
3551
3652msgid ""
@@ -41,36 +57,106 @@ msgstr ""
4157"zainicjuje informacje o długości dla obiektu o zmiennym rozmiarze."
4258
4359msgid ""
44- "Allocate a new Python object using the C structure type *TYPE* and the "
45- "Python type object *typeobj* (``PyTypeObject*``). Fields not defined by the "
46- "Python object header are not initialized. The caller will own the only "
47- "reference to the object (i.e. its reference count will be one). The size of "
48- "the memory allocation is determined from the :c:member:`~PyTypeObject."
49- "tp_basicsize` field of the type object."
60+ "This function only initializes some of the object's memory. It does not "
61+ "zero the rest."
62+ msgstr ""
63+
64+ msgid ""
65+ "Allocates a new Python object using the C structure type *TYPE* and the "
66+ "Python type object *typeobj* (``PyTypeObject*``) by calling :c:func:"
67+ "`PyObject_Malloc` to allocate memory and initializing it like :c:func:"
68+ "`PyObject_Init`. The caller will own the only reference to the object (i.e. "
69+ "its reference count will be one)."
70+ msgstr ""
71+
72+ msgid ""
73+ "Avoid calling this directly to allocate memory for an object; call the "
74+ "type's :c:member:`~PyTypeObject.tp_alloc` slot instead."
75+ msgstr ""
76+
77+ msgid ""
78+ "When populating a type's :c:member:`~PyTypeObject.tp_alloc` slot, :c:func:"
79+ "`PyType_GenericAlloc` is preferred over a custom function that simply calls "
80+ "this macro."
81+ msgstr ""
82+
83+ msgid ""
84+ "This macro does not call :c:member:`~PyTypeObject.tp_alloc`, :c:member:"
85+ "`~PyTypeObject.tp_new` (:meth:`~object.__new__`), or :c:member:"
86+ "`~PyTypeObject.tp_init` (:meth:`~object.__init__`)."
87+ msgstr ""
88+
89+ msgid ""
90+ "This cannot be used for objects with :c:macro:`Py_TPFLAGS_HAVE_GC` set in :c:"
91+ "member:`~PyTypeObject.tp_flags`; use :c:macro:`PyObject_GC_New` instead."
92+ msgstr ""
93+
94+ msgid ""
95+ "Memory allocated by this macro must be freed with :c:func:`PyObject_Free` "
96+ "(usually called via the object's :c:member:`~PyTypeObject.tp_free` slot)."
97+ msgstr ""
98+
99+ msgid ""
100+ "The returned memory is not guaranteed to have been completely zeroed before "
101+ "it was initialized."
50102msgstr ""
51103
52104msgid ""
53- "Note that this function is unsuitable if *typeobj* has :c:macro:"
54- "`Py_TPFLAGS_HAVE_GC` set. For such objects, use :c:func:`PyObject_GC_New` "
55- "instead."
105+ "This macro does not construct a fully initialized object of the given type; "
106+ "it merely allocates memory and prepares it for further initialization by :c:"
107+ "member:`~PyTypeObject.tp_init`. To construct a fully initialized object, "
108+ "call *typeobj* instead. For example::"
109+ msgstr ""
110+
111+ msgid "PyObject *foo = PyObject_CallNoArgs((PyObject *)&PyFoo_Type);"
112+ msgstr ""
113+
114+ msgid ":c:func:`PyObject_Free`"
115+ msgstr ":c:func:`PyObject_Free`"
116+
117+ msgid ":c:macro:`PyObject_GC_New`"
118+ msgstr ""
119+
120+ msgid ":c:func:`PyType_GenericAlloc`"
121+ msgstr ""
122+
123+ msgid ":c:member:`~PyTypeObject.tp_alloc`"
124+ msgstr ":c:member:`~PyTypeObject.tp_alloc`"
125+
126+ msgid "Like :c:macro:`PyObject_New` except:"
56127msgstr ""
57128
58129msgid ""
59- "Allocate a new Python object using the C structure type *TYPE* and the "
60- "Python type object *typeobj* (``PyTypeObject*``). Fields not defined by the "
61- "Python object header are not initialized. The allocated memory allows for "
62- "the *TYPE* structure plus *size* (``Py_ssize_t``) fields of the size given "
63- "by the :c:member:`~PyTypeObject.tp_itemsize` field of *typeobj*. This is "
64- "useful for implementing objects like tuples, which are able to determine "
65- "their size at construction time. Embedding the array of fields into the "
66- "same allocation decreases the number of allocations, improving the memory "
67- "management efficiency."
130+ "It allocates enough memory for the *TYPE* structure plus *size* "
131+ "(``Py_ssize_t``) fields of the size given by the :c:member:`~PyTypeObject."
132+ "tp_itemsize` field of *typeobj*."
133+ msgstr ""
134+
135+ msgid "The memory is initialized like :c:func:`PyObject_InitVar`."
136+ msgstr ""
137+
138+ msgid ""
139+ "This is useful for implementing objects like tuples, which are able to "
140+ "determine their size at construction time. Embedding the array of fields "
141+ "into the same allocation decreases the number of allocations, improving the "
142+ "memory management efficiency."
143+ msgstr ""
144+
145+ msgid ""
146+ "This cannot be used for objects with :c:macro:`Py_TPFLAGS_HAVE_GC` set in :c:"
147+ "member:`~PyTypeObject.tp_flags`; use :c:macro:`PyObject_GC_NewVar` instead."
148+ msgstr ""
149+
150+ msgid ""
151+ "Memory allocated by this function must be freed with :c:func:`PyObject_Free` "
152+ "(usually called via the object's :c:member:`~PyTypeObject.tp_free` slot)."
68153msgstr ""
69154
70155msgid ""
71- "Note that this function is unsuitable if *typeobj* has :c:macro:"
72- "`Py_TPFLAGS_HAVE_GC` set. For such objects, use :c:func:`PyObject_GC_NewVar` "
73- "instead."
156+ "PyObject *list_instance = PyObject_CallNoArgs((PyObject *)&PyList_Type);"
157+ msgstr ""
158+
159+ msgid ":c:macro:`PyObject_GC_NewVar`"
74160msgstr ""
75161
76162msgid "Same as :c:func:`PyObject_Free`."
0 commit comments