mirror of
https://github.com/python/cpython.git
synced 2025-08-01 07:33:08 +00:00
Support for buffer protocol for socket and struct.
* Added socket.recv_buf() and socket.recvfrom_buf() methods, that use the buffer protocol (send and sendto already did). * Added struct.pack_to(), that is the corresponding buffer compatible method to unpack_from(). * Fixed minor typos in arraymodule.
This commit is contained in:
parent
1b94940165
commit
2856e5f390
6 changed files with 550 additions and 220 deletions
|
@ -1975,9 +1975,9 @@ static PyTypeObject Arraytype = {
|
|||
0, /* tp_setattr */
|
||||
0, /* tp_compare */
|
||||
(reprfunc)array_repr, /* tp_repr */
|
||||
0, /* tp_as _number*/
|
||||
&array_as_sequence, /* tp_as _sequence*/
|
||||
&array_as_mapping, /* tp_as _mapping*/
|
||||
0, /* tp_as_number*/
|
||||
&array_as_sequence, /* tp_as_sequence*/
|
||||
&array_as_mapping, /* tp_as_mapping*/
|
||||
0, /* tp_hash */
|
||||
0, /* tp_call */
|
||||
0, /* tp_str */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue