@@ -560,6 +560,8 @@ msgid ""
560560"is used to escape characters that otherwise have a special meaning, such as "
561561"newline, backslash itself, or the quote character."
562562msgstr ""
563+ "自然语言描述: 两种字面值都可以用成对单引号 (``'``) 或双引号 (``\" ``) 来标示首尾。它们也可以用成对的连续三个单引号或双引号来标示首尾"
564+ " (这通常被称为 *三引号字符串*)。反斜杠 (``\\ ``) 字符被用来对特殊含义的字符进行转义,例如换行,反斜杠本身或是引号等字符。"
563565
564566#: ../../reference/lexical_analysis.rst:445
565567msgid ""
@@ -568,6 +570,8 @@ msgid ""
568570"may only contain ASCII characters; bytes with a numeric value of 128 or "
569571"greater must be expressed with escapes."
570572msgstr ""
573+ "字节串字面值总是带有前缀 ``'b'`` 或 ``'B'``;它们生成 :class:`bytes` 类型而非 :class:`str` "
574+ "类型的实例。它们只能包含 ASCII 字符;字节对应数值在128及以上必须以转义形式来表示。"
571575
572576#: ../../reference/lexical_analysis.rst:450
573577msgid ""
@@ -578,19 +582,24 @@ msgid ""
578582"Given that Python 2.x's raw unicode literals behave differently than Python "
579583"3.x's the ``'ur'`` syntax is not supported."
580584msgstr ""
585+ "字符串和字节串字面值都可以带有前缀 ``'r'`` 或 ``'R'``;这种字符串被称为 :dfn:`原始字符串` "
586+ "其中的反斜杠会被当作其本身的字面字符来处理。因此在原始字符串字面值中,``'\\ U'`` 和 ``'\\ u'`` 转义形式不会被特殊对待。由于 "
587+ "Python 2.x 的原始统一码字面值的特性与 Python 3.x 不一致,``'ur'`` 语法已不再被支持。"
581588
582589#: ../../reference/lexical_analysis.rst:457
583590msgid ""
584591"The ``'rb'`` prefix of raw bytes literals has been added as a synonym of "
585592"``'br'``."
586- msgstr ""
593+ msgstr "新加入了表示原始字节串的 ``'rb'`` 前缀,与 ``'br'`` 的意义相同。 "
587594
588595#: ../../reference/lexical_analysis.rst:461
589596msgid ""
590597"Support for the unicode legacy literal (``u'value'``) was reintroduced to "
591598"simplify the maintenance of dual Python 2.x and 3.x codebases. See "
592599":pep:`414` for more information."
593600msgstr ""
601+ "对旧式统一码字面值 (``u'value'``) 的支持被重新引入以简化 Python 2.x 和 3.x 代码库的同步维护。详情见 "
602+ ":pep:`414`。"
594603
595604#: ../../reference/lexical_analysis.rst:466
596605msgid ""
@@ -599,6 +608,9 @@ msgid ""
599608"``'r'``, but not with ``'b'`` or ``'u'``, therefore raw formatted strings "
600609"are possible, but formatted bytes literals are not."
601610msgstr ""
611+ "包含 ``'f'`` 或 ``'F'`` 前缀的字符串字面值称为 :dfn:`格式化字符串字面值`;参见 "
612+ ":ref:`f-strings`。``'f'`` 可与 ``'r'`` 连用,但不能与 ``'b'`` 或 ``'u'`` "
613+ "连用,因此存在原始格式化字符串,但不存在格式化字节串字面值。"
602614
603615#: ../../reference/lexical_analysis.rst:471
604616msgid ""
0 commit comments