File tree Expand file tree Collapse file tree 1 file changed +8
-10
lines changed
Expand file tree Collapse file tree 1 file changed +8
-10
lines changed Original file line number Diff line number Diff line change @@ -299,20 +299,18 @@ Dictionary Objects
299299
300300 On the :term: `free threaded <free threading> ` build, this function can be used safely inside
301301 a critical section. However, the references returned for *pkey * and
302- *pvalue * are :term: `borrowed <borrowed reference> ` and only valid while the critical section is
303- held. If you need to use these objects outside the critical section or when the critical section
302+ *pvalue * are :term: `borrowed <borrowed reference> ` and only valid while the critical section
303+ is held. If you need to use these objects outside the critical section or when the critical section
304304 can be suspended, create :term: `strong reference <strong reference> ` (for example, with
305305 :c:func: `Py_NewRef `).
306306
307- .. code-block:: c
308-
309- Py_BEGIN_CRITICAL_SECTION(self->dict);
310- while (PyDict_Next(self->dict, &pos, &key, &value)) {
311- ...
312- }
313- Py_END_CRITICAL_SECTION();
314-
307+ .. code-block:: c
315308
309+ Py_BEGIN_CRITICAL_SECTION(self->dict);
310+ while (PyDict_Next(self->dict, &pos, &key, &value)) {
311+ ...
312+ }
313+ Py_END_CRITICAL_SECTION ();
316314
317315 .. c :function :: int PyDict_Merge (PyObject *a, PyObject *b, int override)
318316
You can’t perform that action at this time.
0 commit comments