1212# ruoyu zhang <[email protected] >, 20191313# Freesand Leo <[email protected] >, 20191414# kks uch <[email protected] >, 202015+ # zeroswan <[email protected] >, 20201516#
1617#, fuzzy
1718msgid ""
@@ -20,7 +21,7 @@ msgstr ""
2021"Report-Msgid-Bugs-To : \n "
2122"POT-Creation-Date : 2020-05-31 09:25+0000\n "
2223"PO-Revision-Date : 2017-02-16 23:05+0000\n "
23- "Last-Translator : kks uch <951156675@qq .com>, 2020\n "
24+ "Last-Translator : zeroswan <weditor@163 .com>, 2020\n "
2425"Language-Team : Chinese (China) (https://www.transifex.com/python-doc/teams/5390/zh_CN/)\n "
2526"MIME-Version : 1.0\n "
2627"Content-Type : text/plain; charset=UTF-8\n "
@@ -557,23 +558,26 @@ msgid ""
557558"an :attr:`_as_parameter_` attribute and uses this as the function argument."
558559" Of course, it must be one of integer, string, or bytes::"
559560msgstr ""
561+ "你也可以通过自定义 :mod:`ctypes` 参数转换方式来允许自定义类型作为参数。 :mod:`ctypes` 会寻找 "
562+ ":attr:`_as_parameter_` 属性并使用它作为函数参数。当然,它必须是数字、字符串或者二进制字符串::"
560563
561564#: ../../library/ctypes.rst:395
562565msgid ""
563566"If you don't want to store the instance's data in the :attr:`_as_parameter_`"
564567" instance variable, you could define a :class:`property` which makes the "
565568"attribute available on request."
566569msgstr ""
570+ "如果你不想把实例的数据存储到 :attr:`_as_parameter_` 属性。可以通过定义 :class:`property` 函数计算出这个属性。"
567571
568572#: ../../library/ctypes.rst:403
569573msgid "Specifying the required argument types (function prototypes)"
570- msgstr ""
574+ msgstr "指定必选参数的类型(函数原型) "
571575
572576#: ../../library/ctypes.rst:405
573577msgid ""
574578"It is possible to specify the required argument types of functions exported "
575579"from DLLs by setting the :attr:`argtypes` attribute."
576- msgstr ""
580+ msgstr "可以通过设置 :attr:`argtypes` 属性的方法指定从 DLL 中导出函数的必选参数类型。 "
577581
578582#: ../../library/ctypes.rst:408
579583msgid ""
@@ -582,6 +586,8 @@ msgid ""
582586" different types of parameters depending on the format string, on the other "
583587"hand this is quite handy to experiment with this feature)::"
584588msgstr ""
589+ ":attr:`argtypes` 必须是一个 C 数据类型的序列 (这里的 ``printf`` "
590+ "可能不是个好例子,因为它是变长参数,而且每个参数的类型依赖于格式化字符串,不过尝试这个功能也很方便)::"
585591
586592#: ../../library/ctypes.rst:419
587593msgid ""
0 commit comments