mirror of
https://github.com/python/cpython.git
synced 2025-12-31 04:23:37 +00:00
Remove last references to the "char buffer" of the buffer protocol from Python3.
This commit is contained in:
parent
1fbd36b51d
commit
3dcb5acdb0
6 changed files with 11 additions and 77 deletions
|
|
@ -638,21 +638,6 @@ readbuffer_encode(PyObject *self,
|
|||
return codec_tuple(result, size);
|
||||
}
|
||||
|
||||
static PyObject *
|
||||
charbuffer_encode(PyObject *self,
|
||||
PyObject *args)
|
||||
{
|
||||
const char *data;
|
||||
Py_ssize_t size;
|
||||
const char *errors = NULL;
|
||||
|
||||
if (!PyArg_ParseTuple(args, "t#|z:charbuffer_encode",
|
||||
&data, &size, &errors))
|
||||
return NULL;
|
||||
|
||||
return codec_tuple(PyBytes_FromStringAndSize(data, size), size);
|
||||
}
|
||||
|
||||
static PyObject *
|
||||
unicode_internal_encode(PyObject *self,
|
||||
PyObject *args)
|
||||
|
|
@ -1116,7 +1101,6 @@ static PyMethodDef _codecs_functions[] = {
|
|||
{"charmap_decode", charmap_decode, METH_VARARGS},
|
||||
{"charmap_build", charmap_build, METH_VARARGS},
|
||||
{"readbuffer_encode", readbuffer_encode, METH_VARARGS},
|
||||
{"charbuffer_encode", charbuffer_encode, METH_VARARGS},
|
||||
#if defined(MS_WINDOWS) && defined(HAVE_USABLE_WCHAR_T)
|
||||
{"mbcs_encode", mbcs_encode, METH_VARARGS},
|
||||
{"mbcs_decode", mbcs_decode, METH_VARARGS},
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue