@@ -1875,13 +1875,17 @@ msgid ""
1875
1875
" are now picklable and hashable. (Contributed by Yury Selivanov in "
1876
1876
":issue:`20726` and :issue:`20334`.)"
1877
1877
msgstr ""
1878
+ "现在 :class:`~inspect.Signature` 和 :class:`~inspect.Parameter` 类都是可封存和可哈希的对象。 "
1879
+ "(由 Yury Selivanov 在 :issue:`20726` 和 :issue:`20334` 中贡献。)"
1878
1880
1879
1881
#: ../../whatsnew/3.5.rst:1289
1880
1882
msgid ""
1881
1883
"A new :meth:`BoundArguments.apply_defaults() "
1882
1884
"<inspect.BoundArguments.apply_defaults>` method provides a way to set "
1883
1885
"default values for missing arguments::"
1884
1886
msgstr ""
1887
+ "新增的 :meth:`BoundArguments.apply_defaults() "
1888
+ "<inspect.BoundArguments.apply_defaults>` 方法提供了一种为缺失的参数设置默认值的方式::"
1885
1889
1886
1890
#: ../../whatsnew/3.5.rst:1299
1887
1891
msgid "(Contributed by Yury Selivanov in :issue:`24190`.)"
@@ -1894,6 +1898,9 @@ msgid ""
1894
1898
":class:`~inspect.Signature` easier. (Contributed by Yury Selivanov and Eric"
1895
1899
" Snow in :issue:`17373`.)"
1896
1900
msgstr ""
1901
+ "新增的类方法 :meth:`Signature.from_callable() <inspect.Signature.from_callable>` "
1902
+ "使得 :class:`~inspect.Signature` 的子类化更为容易。 (由 Yury Selivanov 和 Eric Snow 在 "
1903
+ ":issue:`17373` 中贡献。)"
1897
1904
1898
1905
#: ../../whatsnew/3.5.rst:1306
1899
1906
msgid ""
@@ -1902,6 +1909,8 @@ msgid ""
1902
1909
"following of ``__wrapped__`` links. (Contributed by Yury Selivanov in "
1903
1910
":issue:`20691`.)"
1904
1911
msgstr ""
1912
+ "现在 :func:`~inspect.signature` 函数接受 *follow_wrapped* 可选关键字参数,当其设为 ``False`` "
1913
+ "时,将禁用 ``__wrapped__`` 链接的自动跟随。 (由 Yury Selivanov 在 :issue:`20691` 中贡献。)"
1905
1914
1906
1915
#: ../../whatsnew/3.5.rst:1311
1907
1916
msgid ""
@@ -1912,6 +1921,11 @@ msgid ""
1912
1921
":func:`~inspect.getcoroutinestate`. (Contributed by Yury Selivanov in "
1913
1922
":issue:`24017` and :issue:`24400`.)"
1914
1923
msgstr ""
1924
+ "新增了一组用于检查 :term:`协程函数 <coroutine function>` 和 :term:`协程对象 <coroutine>` 的函数: "
1925
+ ":func:`~inspect.iscoroutine`, :func:`~inspect.iscoroutinefunction`, "
1926
+ ":func:`~inspect.isawaitable`, :func:`~inspect.getcoroutinelocals` 和 "
1927
+ ":func:`~inspect.getcoroutinestate`。 (由 Yury Selivanov 在 :issue:`24017` 和 "
1928
+ ":issue:`24400` 中贡献。)"
1915
1929
1916
1930
#: ../../whatsnew/3.5.rst:1319
1917
1931
msgid ""
@@ -1920,6 +1934,9 @@ msgid ""
1920
1934
"functions now return a list of named tuples. (Contributed by Daniel Shahaf "
1921
1935
"in :issue:`16808`.)"
1922
1936
msgstr ""
1937
+ "现在 :func:`~inspect.stack`, :func:`~inspect.trace`, "
1938
+ ":func:`~inspect.getouterframes` 和 :func:`~inspect.getinnerframes` "
1939
+ "函数将返回具名元组的列表。 (由 Daniel Shahaf 在 :issue:`16808` 中贡献。)"
1923
1940
1924
1941
#: ../../whatsnew/3.5.rst:1326
1925
1942
msgid "io"
@@ -1933,6 +1950,10 @@ msgid ""
1933
1950
"<io.RawIOBase.readinto>` methods. (Contributed by Nikolaus Rath in "
1934
1951
":issue:`20578`.)"
1935
1952
msgstr ""
1953
+ "新增 :meth:`BufferedIOBase.readinto1() <io.BufferedIOBase.readinto1>` "
1954
+ "方法,该方法会使用至少一次对下层原始流的调用 :meth:`RawIOBase.read() <io.RawIOBase.read>` 或 "
1955
+ ":meth:`RawIOBase.readinto() <io.RawIOBase.readinto>` 方法。 (由 Nikolaus Rath 在 "
1956
+ ":issue:`20578` 中贡献。)"
1936
1957
1937
1958
#: ../../whatsnew/3.5.rst:1336
1938
1959
msgid &quo
8000
t;ipaddress"
@@ -1944,6 +1965,8 @@ msgid ""
1944
1965
" classes now accept an ``(address, netmask)`` tuple argument, so as to "
1945
1966
"easily construct network objects from existing addresses::"
1946
1967
msgstr ""
1968
+ "现在 :class:`~ipaddress.IPv4Network` 和 :class:`~ipaddress.IPv6Network` 类均接受一个 "
1969
+ "``(address, netmask)`` 元组参数,可以根据现有地址方便地构造网络对象::"
1947
1970
1948
1971
#: ../../whatsnew/3.5.rst:1348
1949
1972
msgid "(Contributed by Peter Moody and Antoine Pitrou in :issue:`16531`.)"
@@ -1955,6 +1978,8 @@ msgid ""
1955
1978
":class:`~ipaddress.IPv4Network` and :class:`~ipaddress.IPv6Network` classes "
1956
1979
"returns the name of the reverse DNS PTR record::"
1957
1980
msgstr ""
1981
+ "新增 :class:`~ipaddress.IPv4Network` 和 :class:`~ipaddress.IPv6Network` 类的 "
1982
+ ":attr:`~ipaddress.IPv4Network.reverse_pointer` 属性用于返回 DNS PTR 反向记录的名称::"
1958
1983
1959
1984
#: ../../whatsnew/3.5.rst:1362
1960
1985
msgid "(Contributed by Leon Weber in :issue:`20480`.)"
@@ -1971,6 +1996,8 @@ msgid ""
1971
1996
" to sort the keys alphabetically. (Contributed by Berker Peksag in "
1972
1997
":issue:`21650`.)"
1973
1998
msgstr ""
1999
+ "现在 :mod:`json.tool` 命令行接口会保留输入中传入的 JSON 对象中键的顺序。 新的 ``--sort-keys`` "
2000
+ "选项可用于按字母顺序对键进行排序。 (由 Berker Peksag 在 :issue:`21650` 中贡献。)"
1974
2001
1975
2002
#: ../../whatsnew/3.5.rst:1373
1976
2003
msgid ""
0 commit comments