diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2015-04-03 20:53:51 (GMT) |
---|---|---|
committer | Serhiy Storchaka <storchaka@gmail.com> | 2015-04-03 20:53:51 (GMT) |
commit | 1009bf18b38a8d36298575191dd8fdf43f8f9097 (patch) | |
tree | 18860fdef30c931dc2ea177059e96b69a49fa04f /Modules/_opcode.c | |
parent | 0759f84d6260bad1234b802212e73fdc5873d261 (diff) | |
download | cpython-1009bf18b38a8d36298575191dd8fdf43f8f9097.zip cpython-1009bf18b38a8d36298575191dd8fdf43f8f9097.tar.gz cpython-1009bf18b38a8d36298575191dd8fdf43f8f9097.tar.bz2 |
Issue #23501: Argumen Clinic now generates code into separate files by default.
Diffstat (limited to 'Modules/_opcode.c')
-rw-r--r-- | Modules/_opcode.c | 37 |
1 files changed, 3 insertions, 34 deletions
diff --git a/Modules/_opcode.c b/Modules/_opcode.c index fee388f..663bb21 100644 --- a/Modules/_opcode.c +++ b/Modules/_opcode.c @@ -6,6 +6,8 @@ module _opcode [clinic start generated code]*/ /*[clinic end generated code: output=da39a3ee5e6b4b0d input=117442e66eb376e6]*/ +#include "clinic/_opcode.c.h" + /*[clinic input] _opcode.stack_effect -> int @@ -17,42 +19,9 @@ _opcode.stack_effect -> int Compute the stack effect of the opcode. [clinic start generated code]*/ -PyDoc_STRVAR(_opcode_stack_effect__doc__, -"stack_effect($module, opcode, oparg=None, /)\n" -"--\n" -"\n" -"Compute the stack effect of the opcode."); - -#define _OPCODE_STACK_EFFECT_METHODDEF \ - {"stack_effect", (PyCFunction)_opcode_stack_effect, METH_VARARGS, _opcode_stack_effect__doc__}, - -static int -_opcode_stack_effect_impl(PyModuleDef *module, int opcode, PyObject *oparg); - -static PyObject * -_opcode_stack_effect(PyModuleDef *module, PyObject *args) -{ - PyObject *return_value = NULL; - int opcode; - PyObject *oparg = Py_None; - int _return_value; - - if (!PyArg_ParseTuple(args, - "i|O:stack_effect", - &opcode, &oparg)) - goto exit; - _return_value = _opcode_stack_effect_impl(module, opcode, oparg); - if ((_return_value == -1) && PyErr_Occurred()) - goto exit; - return_value = PyLong_FromLong((long)_return_value); - -exit: - return return_value; -} - static int _opcode_stack_effect_impl(PyModuleDef *module, int opcode, PyObject *oparg) -/*[clinic end generated code: output=9e1133f8d587bc67 input=2d0a9ee53c0418f5]*/ +/*[clinic end generated code: output=1fcafd5596c6b050 input=2d0a9ee53c0418f5]*/ { int effect; int oparg_int = 0; |