@@ -453,13 +453,17 @@ msgid ""
453453"*module* and *registry* arguments may be set to ``NULL`` to get the default "
454454"effect described there."
455455msgstr ""
456+ "发出一个对所有警告属性进行显式控制的警告消息。 这是位于 Python 函数 :func:`warnings.warn_explicit` "
457+ "外层的直接包装;请查看其文档了解详情。 *module* 和 *registry* 参数可被设为 ``NULL`` 以得到相关文档所描述的默认效果。"
456458
457459#: ../../c-api/exceptions.rst:345
458460msgid ""
459461"Similar to :c:func:`PyErr_WarnExplicitObject` except that *message* and "
460462"*module* are UTF-8 encoded strings, and *filename* is decoded from the "
461463":term:`filesystem encoding and error handler`."
462464msgstr ""
465+ "类似于 :c:func:`PyErr_WarnExplicitObject` 不过 *message* 和 *module* 是 UTF-8 "
466+ "编码的字符串,而 *filename* 是由 :term:`filesystem encoding and error handler` 解码的。"
463467
464468#: ../../c-api/exceptions.rst:352
465469msgid ""
@@ -507,6 +511,8 @@ msgid ""
507511" in the case of a class exception, or it may be a subclass of the expected "
508512"exception.)"
509513msgstr ""
514+ "不要将返回值与特定的异常进行比较;请改为使用 :c:func:`PyErr_ExceptionMatches`,如下所示。 "
515+ "(比较很容易失败因为对于类异常来说,异常可能是一个实例而不是类,或者它可能是预期的异常的一个子类。)"
510516
511517#: ../../c-api/exceptions.rst:390
512518msgid ""
@@ -524,6 +530,8 @@ msgid ""
524530"instance of a subclass. If *exc* is a tuple, all exception types in the "
525531"tuple (and recursively in subtuples) are searched for a match."
526532msgstr ""
533+ "如果 *given* 异常与 *exc* 中的异常类型相匹配则返回真值。 如果 *exc* 是一个类对象,则当 *given* "
534+ "是一个子类的实例时也将返回真值。 如果 *exc* 是一个元组,则该元组(以及递归的子元组)中的所有异常类型都将被搜索进行匹配。"
527535
528536#: ../../c-api/exceptions.rst:405
529537msgid ""
@@ -533,13 +541,15 @@ msgid ""
533541"object retrieved. The value and traceback object may be ``NULL`` even when "
534542"the type object is not."
535543msgstr ""
544+ "将错误指示符提取到三个变量中并传递其地址。 如果未设置错误指示符,则将三个变量都设为 ``NULL``。 "
545+ "如果已设置,则将其清除并且你将得到对所提取的每个对象的引用。 值和回溯对象可以为 ``NULL`` 即使类型对象不为空。"
536546
537547#: ../../c-api/exceptions.rst:412
538548msgid ""
539549"This function is normally only used by code that needs to catch exceptions "
540550"or by code that needs to save and restore the error indicator temporarily, "
541551"e.g.::"
542- msgstr ""
552+ msgstr "此函数通常只被需要捕获异常的代码或需要临时保存和恢复错误指示符的代码所使用,例如:: "
543553
544554#: ../../c-api/exceptions.rst:427
545555msgid ""
0 commit comments