@@ -2092,12 +2092,15 @@ msgid ""
20922092" by the current thread and the previously interpreter's GIL will remain "
20932093"released here."
20942094msgstr ""
2095+ "与所有其他 Python/C API 函数一样,在调用此函数之前必须先持有全局解释器锁并且在其返回时仍继续持有。 "
2096+ "同样地在进入函数时也必须设置当前线程状态。 执行成功后,返回的线程状态将被设为当前线程状态。 如果创建的子解释器具有自己的 GIL 那么调用方解释器的 "
2097+ "GIL 将被释放。 当此函数返回时,新的解释器的 GIL 将由当前线程持有而之前的解释器的 GIL 在此将保持释放状态。"
20952098
20962099#: ../../c-api/init.rst:1629
20972100msgid ""
20982101"Sub-interpreters are most effective when isolated from each other, with "
20992102"certain functionality restricted::"
2100- msgstr ""
2103+ msgstr "子解释器在彼此相互隔离,并让特定功能受限的情况下是最有效率的:: "
21012104
21022105#: ../../c-api/init.rst:1643
21032106msgid ""
@@ -2106,10 +2109,12 @@ msgid ""
21062109":c:type:`PyInterpreterState` values. A read-only copy of the config may be "
21072110"stored internally on the :c:type:`PyInterpreterState`."
21082111msgstr ""
2112+ "请注意该配置只会被短暂使用而不会被修改。 在初始化期间配置的值会被转换成各种 :c:type:`PyInterpreterState` 值。 "
2113+ "配置的只读副本可以被内部存储于 :c:type:`PyInterpreterState` 中。"
21092114
21102115#: ../../c-api/init.rst:1652
21112116msgid "Extension modules are shared between (sub-)interpreters as follows:"
2112- msgstr ""
2117+ msgstr "扩展模块将以如下方式在(子)解释器之间共享: "
21132118
21142119#: ../../c-api/init.rst:1654
21152120msgid ""
@@ -2118,6 +2123,8 @@ msgid ""
21182123"initialized for each interpreter. Only C-level static and global variables "
21192124"are shared between these module objects."
21202125msgstr ""
2126+ "对于使用多阶段初始化的模块 ,例如 :c:func:`PyModule_FromDefAndSpec`,将为每个解释器创建并初始化一个单独的模块对象。 "
2127+ "只有 C 层级的静态和全局变量能在这些模块 对象之间共享。"
21212128
21222129#: ../../c-api/init.rst:1660
21232130msgid ""
0 commit comments