Kaydet (Commit) f256c22f authored tarafından Larry Hastings's avatar Larry Hastings

Fix for catestrophic errors in previous checkin (Argument Clinic rollup patch).

üst c2047264
......@@ -56,6 +56,8 @@ typedef struct {
#endif
} BZ2Decompressor;
static PyTypeObject BZ2Compressor_Type;
static PyTypeObject BZ2Decompressor_Type;
/* Helper functions. */
......@@ -204,7 +206,7 @@ class _bz2.BZ2Decompressor "BZ2Decompressor *" "&BZ2Decompressor_Type"
[clinic start generated code]*/
/*[clinic end generated code: checksum=da39a3ee5e6b4b0d3255bfef95601890afd80709]*/
#include "_bz2module.clinic.c"
#include "clinic/_bz2module.c.h"
/*[clinic input]
_bz2.BZ2Compressor.compress
......
This diff is collapsed.
......@@ -1812,7 +1812,7 @@ audioop_adpcm2lin_impl(PyModuleDef *module, Py_buffer *fragment, int width, PyOb
return rv;
}
#include "audioop.clinic.c"
#include "clinic/audioop.c.h"
static PyMethodDef audioop_methods[] = {
AUDIOOP_MAX_METHODDEF
......
......@@ -236,7 +236,7 @@ ascii_buffer_converter(PyObject *arg, Py_buffer *buf)
return Py_CLEANUP_SUPPORTED;
}
#include "binascii.clinic.c"
#include "clinic/binascii.c.h"
/*[clinic input]
binascii.a2b_uu
......
......@@ -75,8 +75,7 @@ _bz2_BZ2Compressor___init__(PyObject *self, PyObject *args, PyObject *kwargs)
int return_value = -1;
int compresslevel = 9;
if (({self_name} == {self_type_object}) &&
!_PyArg_NoKeywords("BZ2Compressor", kwargs))
if (!_PyArg_NoKeywords("BZ2Compressor", kwargs))
goto exit;
if (!PyArg_ParseTuple(args,
"|i:BZ2Compressor",
......@@ -138,15 +137,13 @@ _bz2_BZ2Decompressor___init__(PyObject *self, PyObject *args, PyObject *kwargs)
{
int return_value = -1;
if (({self_name} == {self_type_object}) &&
!_PyArg_NoPositional("BZ2Decompressor", args))
if (!_PyArg_NoPositional("BZ2Decompressor", args))
goto exit;
if (({self_name} == {self_type_object}) &&
!_PyArg_NoKeywords("BZ2Decompressor", kwargs))
if (!_PyArg_NoKeywords("BZ2Decompressor", kwargs))
goto exit;
return_value = _bz2_BZ2Decompressor___init___impl((BZ2Decompressor *)self);
exit:
return return_value;
}
/*[clinic end generated code: checksum=79ee0d9731dfe404baec35b704b2ca2179b9a6c0]*/
/*[clinic end generated code: checksum=9bb33ae7d35494b7a5365f03f390e4b5b8b1bc49]*/
This diff is collapsed.
......@@ -2593,7 +2593,11 @@ class self_converter(CConverter):
def set_template_dict(self, template_dict):
template_dict['self_name'] = self.name
template_dict['self_type'] = self.parser_type
template_dict['self_type_check'] = '({self_name} == {self_type_object}) &&\n '
if ((self.function.kind == METHOD_NEW) and
self.function.cls and
self.function.cls.typedef):
template_dict['self_type_object'] = self.function.cls.type_object
template_dict['self_type_check'] = '({self_name} == {self_type_object}) &&\n '.format_map(template_dict)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment