Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 8c1d3cc

Browse files
[po] auto sync
1 parent 1f5fd3c commit 8c1d3cc

2 files changed

Lines changed: 6 additions & 1 deletion

File tree

.stat.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{"translation": "95.33%", "updated_at": "2024-07-06T07:47:12Z"}
1+
{"translation": "95.33%", "updated_at": "2024-07-08T08:46:56Z"}

whatsnew/2.2.po

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -502,6 +502,11 @@ msgid ""
502502
"with this in mind. Finally, calling a function on every attribute access "
503503
"results in a sizable performance loss."
504504
msgstr ""
505+
"然而,Python 2.2 对 :dfn:`properties` 的支持通常是捕获属性引用的更简单方法。编写 :meth:`!__getattr__`"
506+
" 方法非常复杂,因为为了避免递归,你不能在其中使用常规的属性访问,而是不得不处理 :attr:`~object.__dict__` "
507+
"的内容。此外,:meth:`~object.__getattr__` 方法在 Python 检查其他例如 "
508+
":meth:`~object.__repr__` 或 :meth:`!__coerce__` "
509+
"等方法时也会被调用,因此在编写时需要考虑这些情况。最后,每次属性访问都调用一个函数会导致显著的性能损失。"
505510

506511
#: ../../whatsnew/2.2.rst:337
507512
msgid ""

0 commit comments

Comments
 (0)