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 { ...@@ -56,6 +56,8 @@ typedef struct {
#endif #endif
} BZ2Decompressor; } BZ2Decompressor;
static PyTypeObject BZ2Compressor_Type;
static PyTypeObject BZ2Decompressor_Type;
/* Helper functions. */ /* Helper functions. */
...@@ -204,7 +206,7 @@ class _bz2.BZ2Decompressor "BZ2Decompressor *" "&BZ2Decompressor_Type" ...@@ -204,7 +206,7 @@ class _bz2.BZ2Decompressor "BZ2Decompressor *" "&BZ2Decompressor_Type"
[clinic start generated code]*/ [clinic start generated code]*/
/*[clinic end generated code: checksum=da39a3ee5e6b4b0d3255bfef95601890afd80709]*/ /*[clinic end generated code: checksum=da39a3ee5e6b4b0d3255bfef95601890afd80709]*/
#include "_bz2module.clinic.c" #include "clinic/_bz2module.c.h"
/*[clinic input] /*[clinic input]
_bz2.BZ2Compressor.compress _bz2.BZ2Compressor.compress
......
This diff is collapsed.
...@@ -1812,7 +1812,7 @@ audioop_adpcm2lin_impl(PyModuleDef *module, Py_buffer *fragment, int width, PyOb ...@@ -1812,7 +1812,7 @@ audioop_adpcm2lin_impl(PyModuleDef *module, Py_buffer *fragment, int width, PyOb
return rv; return rv;
} }
#include "audioop.clinic.c" #include "clinic/audioop.c.h"
static PyMethodDef audioop_methods[] = { static PyMethodDef audioop_methods[] = {
AUDIOOP_MAX_METHODDEF AUDIOOP_MAX_METHODDEF
......
...@@ -236,7 +236,7 @@ ascii_buffer_converter(PyObject *arg, Py_buffer *buf) ...@@ -236,7 +236,7 @@ ascii_buffer_converter(PyObject *arg, Py_buffer *buf)
return Py_CLEANUP_SUPPORTED; return Py_CLEANUP_SUPPORTED;
} }
#include "binascii.clinic.c" #include "clinic/binascii.c.h"
/*[clinic input] /*[clinic input]
binascii.a2b_uu binascii.a2b_uu
......
...@@ -75,8 +75,7 @@ _bz2_BZ2Compressor___init__(PyObject *self, PyObject *args, PyObject *kwargs) ...@@ -75,8 +75,7 @@ _bz2_BZ2Compressor___init__(PyObject *self, PyObject *args, PyObject *kwargs)
int return_value = -1; int return_value = -1;
int compresslevel = 9; int compresslevel = 9;
if (({self_name} == {self_type_object}) && if (!_PyArg_NoKeywords("BZ2Compressor", kwargs))
!_PyArg_NoKeywords("BZ2Compressor", kwargs))
goto exit; goto exit;
if (!PyArg_ParseTuple(args, if (!PyArg_ParseTuple(args,
"|i:BZ2Compressor", "|i:BZ2Compressor",
...@@ -138,15 +137,13 @@ _bz2_BZ2Decompressor___init__(PyObject *self, PyObject *args, PyObject *kwargs) ...@@ -138,15 +137,13 @@ _bz2_BZ2Decompressor___init__(PyObject *self, PyObject *args, PyObject *kwargs)
{ {
int return_value = -1; int return_value = -1;
if (({self_name} == {self_type_object}) && if (!_PyArg_NoPositional("BZ2Decompressor", args))
!_PyArg_NoPositional("BZ2Decompressor", args))
goto exit; goto exit;
if (({self_name} == {self_type_object}) && if (!_PyArg_NoKeywords("BZ2Decompressor", kwargs))
!_PyArg_NoKeywords("BZ2Decompressor", kwargs))
goto exit; goto exit;
return_value = _bz2_BZ2Decompressor___init___impl((BZ2Decompressor *)self); return_value = _bz2_BZ2Decompressor___init___impl((BZ2Decompressor *)self);
exit: exit:
return return_value; 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): ...@@ -2593,7 +2593,11 @@ class self_converter(CConverter):
def set_template_dict(self, template_dict): def set_template_dict(self, template_dict):
template_dict['self_name'] = self.name template_dict['self_name'] = self.name
template_dict['self_type'] = self.parser_type 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