File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- {"translation" : " 92.11 %" , "updated_at" : " 2023-11-10T14:57:04Z " }
1+ {"translation" : " 92.12 %" , "updated_at" : " 2023-11-10T15:56:01Z " }
Original file line number Diff line number Diff line change @@ -2255,6 +2255,8 @@ msgid ""
22552255"such as incorrect types. See also :term:`type hints <type hint>` and the "
22562256":mod:`typing` module."
22572257msgstr ""
2258+ "读取 Python 代码并进行分析,以查找问题例如拼写错误的外部工具。 另请参阅 :term:`类型提示 <type hint>` 以及 "
2259+ ":mod:`typing` 模块。"
22582260
22592261#: ../../glossary.rst:1139
22602262msgid "strong reference"
@@ -2401,6 +2403,8 @@ msgid ""
24012403"to :term:`static type checkers <static type checker>`. They can also aid "
24022404"IDEs with code completion and refactoring."
24032405msgstr ""
2406+ "类型提示是可选的而不是 Python 的强制要求,但它们对 :term:`静态类型检查器 <static type checker>` 很有用处。 "
2407+ "它们还能协助 IDE 实现代码补全与重构。"
24042408
24052409#: ../../glossary.rst:1219
24062410msgid ""
Original file line number Diff line number Diff line change @@ -750,3 +750,8 @@ msgid ""
750750"textual or binary data, helping to make sure everything functions as "
751751"expected in both versions of Python."
752752msgstr ""
753+ "另一个帮助移植你的代码的办法是在你的代码上使用 :term:`static type checker` 如 mypy_ 或 pytype_。 "
754+ "这些工具可以用来分析你的代码,就像它在 Python 2 中运行一样,然后你可以第二次运行这个工具,就像你的代码在 Python 3 中运行一样。 "
755+ "通过像这样两次运行静态类型检查器,你可以发现你在不同的 Python 版本中是否错误地使用了二进制数据类型。 "
756+ "如果你在你的代码中添加了可选的类型提示,你还可以明确说明你的 API 是使用文本还是二进制数据,这有助于确保在两个版本的 Python "
757+ "中所有的功能都符合预期。."
You can’t perform that action at this time.
0 commit comments