| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -4793,6 +4793,16 @@ static PyMappingMethods Array_as_mapping = { | |||
| 4793 | 4793 | Array_ass_subscript, | |
| 4794 | 4794 | }; | |
| 4795 | 4795 | ||
| 4796 | + PyDoc_STRVAR(array_doc, | ||
| 4797 | + "Abstract base class for arrays.\n" | ||
| 4798 | + "\n" | ||
| 4799 | + "The recommended way to create concrete array types is by multiplying any\n" | ||
| 4800 | + "ctypes data type with a non-negative integer. Alternatively, you can subclass\n" | ||
| 4801 | + "this type and define _length_ and _type_ class variables. Array elements can\n" | ||
| 4802 | + "be read and written using standard subscript and slice accesses for slice\n" | ||
| 4803 | + "reads, the resulting object is not itself an Array." | ||
| 4804 | + ); | ||
| 4805 | + | ||
| 4796 | 4806 | PyTypeObject PyCArray_Type = { | |
| 4797 | 4807 | PyVarObject_HEAD_INIT(NULL, 0) | |
| 4798 | 4808 | "_ctypes.Array", | |
@@ -4813,8 +4823,8 @@ PyTypeObject PyCArray_Type = { | |||
| 4813 | 4823 | 0, /* tp_getattro */ | |
| 4814 | 4824 | 0, /* tp_setattro */ | |
| 4815 | 4825 | &PyCData_as_buffer, /* tp_as_buffer */ | |
| 4816 | - Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, /* tp_flags */ | ||
| 4817 | - PyDoc_STR("XXX to be provided"), /* tp_doc */ | ||
| 4826 | + Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, /* tp_flags */ | ||
| 4827 | + array_doc, /* tp_doc */ | ||
| 4818 | 4828 | (traverseproc)PyCData_traverse, /* tp_traverse */ | |
| 4819 | 4829 | (inquiry)PyCData_clear, /* tp_clear */ | |
| 4820 | 4830 | 0, /* tp_richcompare */ | |
| Back | FazBrowse Home | New Git URL |
0 commit comments