11# SOME DESCRIPTIVE TITLE.
2- # Copyright (C) 2001-2022 , Python Software Foundation
2+ # Copyright (C) 2001-2023 , Python Software Foundation
33# This file is distributed under the same license as the Python package.
44# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
55#
66# Translators:
7- # Shengjing Zhu <[email protected] >, 20218- # ww song <[email protected] >, 20219- # ppcfish <[email protected] >, 202110- # WH-2099 <[email protected] >, 202111- # Freesand Leo <[email protected] >, 202112- # Alpha Du <[email protected] >, 20227+ # Rafael Fontenelle <[email protected] >, 2023138#
149#, fuzzy
1510msgid ""
1611msgstr ""
17- "Project-Id-Version : Python 3.10 \n "
12+ "Project-Id-Version : Python 3.11 \n "
1813"Report-Msgid-Bugs-To : \n "
19- "POT-Creation-Date : 2022-11-04 14:28 +0000\n "
20- "PO-Revision-Date : 2021-06-28 00:52 +0000\n "
21- "Last-Translator : Alpha Du <alphanow @gmail.com>, 2022 \n "
22- "Language-Team : Chinese (China) (https://www .transifex.com/python-doc/teams/5390/zh_CN/)\n "
14+ "POT-Creation-Date : 2023-08-25 14:43 +0000\n "
15+ "PO-Revision-Date : 2023-05-24 02:10 +0000\n "
16+ "Last-Translator : Rafael Fontenelle <rffontenelle @gmail.com>, 2023 \n "
17+ "Language-Team : Chinese (China) (https://app .transifex.com/python-doc/teams/5390/zh_CN/)\n "
2318"MIME-Version : 1.0\n "
2419"Content-Type : text/plain; charset=UTF-8\n "
2520"Content-Transfer-Encoding : 8bit\n "
@@ -36,22 +31,23 @@ msgstr "目录"
3631
3732#: ../../faq/design.rst:11
3833msgid "Why does Python use indentation for grouping of statements?"
39- msgstr "为什么Python使用缩进来分组语句 ?"
34+ msgstr "为什么 Python 使用缩进来分组语句 ?"
4035
4136#: ../../faq/design.rst:13
4237msgid ""
4338"Guido van Rossum believes that using indentation for grouping is extremely "
4439"elegant and contributes a lot to the clarity of the average Python program. "
4540"Most people learn to love this feature after a while."
4641msgstr ""
47- "Guido van Rossum 认为使用缩进进行分组非常优雅,并且大大提高了普通Python程序的清晰度。大多数人在一段时间后就学会并喜欢上这个功能。"
42+ "Guido van Rossum 认为使用缩进进行分组非常优雅,并且大大提高了普通 Python 程序的清晰度。 "
43+ "大多数人在一段时间后就会喜欢上这个特性。"
4844
4945#: ../../faq/design.rst:17
5046msgid ""
5147"Since there are no begin/end brackets there cannot be a disagreement between"
5248" grouping perceived by the parser and the human reader. Occasionally C "
5349"programmers will encounter a fragment of code like this::"
54- msgstr "由于没有开始/结束括号,因此解析器感知的分组与人类读者之间不会存在分歧。偶尔C程序员会遇到像这样的代码片段 ::"
50+ msgstr "由于没有开始/结束括号,因此解析器感知的分组与人类读者之间不会存在分歧。 偶尔 C 程序员会遇到像这样的代码片段 ::"
5551
5652#: ../../faq/design.rst:26
5753msgid ""
@@ -61,7 +57,7 @@ msgid ""
6157"decremented even for ``x > y``."
6258msgstr ""
6359"如果条件为真,则只执行 ``x++`` 语句,但缩进会使你认为情况并非如此。 即使是经验丰富的 C 程序员有时也会长久地盯着它发呆,不明白为什么在 "
64- "``x > y``时 ``y`` 也会减少。"
60+ "``x > y`` 时 ``y`` 也会减少。"
6561
6662#: ../../faq/design.rst:31
6763msgid ""
@@ -71,7 +67,7 @@ msgid ""
7167"style, it is normal to feel somewhat uneasy when reading (or being required "
7268"to write) in a different one."
7369msgstr ""
74- "因为没有开始/结束花括号,所以 Python 更不容易发生编码风格冲突 。 在 C 中有许多不同的放置花括号的方式。 "
70+ "因为没有开始/结束花括号,所以 Python 更不容易发生代码风格冲突 。 在 C 中有许多不同的放置花括号的方式。 "
7571"在习惯了阅读和编写某种特定风格的代码之后,当阅读(或被要求编写)另一种风格的代码时通常都会令人感觉有点不舒服)。"
7672
7773#: ../../faq/design.rst:38
@@ -84,9 +80,9 @@ msgid ""
8480"brackets -- the lack of declarations and the high-level data types are also "
8581"responsible -- but the indentation-based syntax certainly helps."
8682msgstr ""
87- "许多编码风格将开始/结束括号单独放在一行上。这使得程序相当长,浪费了宝贵的屏幕空间,使得更难以对程序进行全面的了解。理想情况下,函数应该适合一个屏幕(例如,20 "
88- "--30行)。 20行Python可以完成比20行C更多的工作。这不仅仅是由于缺少开始/结束括号 -- 缺少声明和高级数据类型也是其中的原因 -- "
89- "但缩进基于语法肯定有帮助 。"
83+ "许多编码风格将开始/结束括号单独放在一行上。这使得程序相当长,浪费了宝贵的屏幕空间,使得更难以对程序进行全面的了解。 "
84+ "理想情况下,函数应该适合一个屏幕(例如,20 --30行)。 20 行 Python 可以完成比 20 行 C 更多的工作。 "
85+ "这不仅仅是由于没有开始/结束括号 -- 无需声明以及高层级的数据类型也是其中的原因 -- 但基于缩进的语法肯定有帮助 。"
9086
9187#: ../../faq/design.rst:48
9288msgid "Why am I getting strange results with simple arithmetic operations?"
@@ -257,7 +253,7 @@ msgstr "自 Python 3.8 开始,你能做到的!"
257253msgid ""
258254"Assignment expressions using the walrus operator ``:=`` assign a variable in"
259255" an expression::"
260- msgstr ""
256+ msgstr "赋值表达式使用海象运算符 ``:=`` 在表达式中为变量赋值:: "
261257
262258#: ../../faq/design.rst:164
263259msgid "See :pep:`572` for more information."
@@ -475,6 +471,8 @@ msgid ""
475471"(which is exactly the same type of object that a lambda expression yields) "
476472"is assigned!"
477473msgstr ""
474+ "函数已经是 Python 中的第一等对象,最可在局部作用域中声明。 因此使用 lambda 而非局部定义函数的唯一优点是你不需要为函数指定名称 -- "
475+ "但那只是一个被赋值为函数对象(它的类型与 lambda 表达式所产生的对象完全相同)的局部变量!"
478476
479477#: ../../faq/design.rst:322
480478msgid "Can Python be compiled to machine code, C or some other language?"
@@ -487,6 +485,8 @@ msgid ""
487485" is an up-and-coming compiler of Python into C++ code, aiming to support the"
488486" full Python language."
489487msgstr ""
488+ "`Cython <https://cython.org/>`_ 会将带有可选标注的修改版 Python 编译为 C 扩展。 `Nuitka "
489+ "<https://www.nuitka.net/>`_ 是一个 Python 至 C++ 代码的新兴编译器,它的目标是支持完整的 Python 语言。"
490490
491491#: ../../faq/design.rst:331
492492msgid "How does Python manage memory?"
@@ -514,6 +514,9 @@ msgid ""
514514"porting problems if your Python code depends on the behavior of the "
515515"reference counting implementation."
516516msgstr ""
517+ "不同,其他实现 (如 `Jython <https://www.jython.org>`_ 或 `PyPy "
518+ "<https://www.pypy.org>`_) 可能会依赖不同的机制,如完全的垃圾回收器。 如果你的 Python "
519+ "代码依赖于引用计数实现的行为则这种差异可能会导致某些微妙的移植问题。"
517520
518521#: ../../faq/design.rst:347
519522msgid ""
@@ -789,7 +792,7 @@ msgid ""
789792"and other hash based structures will misbehave."
790793msgstr ""
791794"此外,必须始终如此,如果 ``o1 == o2`` (即 ``o1.__eq__(o2) is True`` )则 ``hash(o1) == "
792- "hash(o2)``(即 ``o1.__hash__() == o2.__hash__()`` ),无论对象是否在字典中。 "
795+ "hash(o2)`` (即 ``o1.__hash__() == o2.__hash__()`` ),无论对象是否在字典中。 "
793796"如果你不能满足这些限制,字典和其他基于 hash 的结构将会出错。"
794797
795798#: ../../faq/design.rst:531
@@ -852,7 +855,7 @@ msgstr ""
852855"Python 2.6添加了一个 :mod:`abc` 模块,允许定义抽象基类 (ABCs)。然后可以使用 :func:`isinstance` 和 "
853856":func:`issubclass` 来检查实例或类是否实现了特定的ABC。 :mod:`collections.abc` 模块定义了一组有用的ABCs"
854857" 例如 :class:`~collections.abc.Iterable` , :class:`~collections.abc.Container`"
855- " , 和 :class:`~collections.abc.MutableMapping` "
858+ " , 和 :class:`~collections.abc.MutableMapping`"
856859
857860#: ../../faq/design.rst:570
858861msgid ""
@@ -879,14 +882,12 @@ msgid ""
879882"An appropriate testing discipline can help build large complex applications "
880883"in Python as well as having interface specifications would. In fact, it can"
881884" be better because an interface specification cannot test certain properties"
882- " of a program. For example, the :meth:`append` method is expected to add "
883- "new elements to the end of some internal list; an interface specification "
884- "cannot test that your :meth:`append` implementation will actually do this "
885- "correctly, but it's trivial to check this property in a test suite."
885+ " of a program. For example, the :meth:`!list.append` method is expected to "
886+ "add new elements to the end of some internal list; an interface "
887+ "specification cannot test that your :meth:`!list.append` implementation will"
888+ " actually do this correctly, but it's trivial to check this property in a "
889+ "test suite."
886890msgstr ""
887- "适当的测试规程可以帮助在Python中构建大型的、复杂的应用程序以及接口规范。事实上,它可能会更好,因为接口规范不能测试程序的某些属性。例如, "
888- ":meth:`append` 方法将向一些内部列表的末尾添加新元素;接口规范不能测试您的 :meth:`append` "
889- "实现是否能够正确执行此操作,但是在测试套件中检查这个属性是很简单的。"
890891
891892#: ../../faq/design.rst:589
892893msgid ""
@@ -1051,7 +1052,7 @@ msgstr ""
10511052
10521053#: ../../faq/design.rst:717
10531054msgid "Why are colons required for the if/while/def/class statements?"
1054- msgstr "为什么 if/while/def/class语句需要冒号? "
1055+ msgstr "为什么 if/while/def/class语句需要冒号?"
10551056
10561057#: ../../faq/design.rst:719
10571058msgid ""
0 commit comments