Serhiy Storchaka | 5106ad1 | 2017-02-04 12:13:20 +0200 | [diff] [blame] | 1 | /*[clinic input] |
| 2 | preserve |
| 3 | [clinic start generated code]*/ |
| 4 | |
| 5 | PyDoc_STRVAR(_symtable_symtable__doc__, |
| 6 | "symtable($module, str, filename, startstr, /)\n" |
| 7 | "--\n" |
| 8 | "\n" |
| 9 | "Return symbol and scope dictionaries used internally by compiler."); |
| 10 | |
| 11 | #define _SYMTABLE_SYMTABLE_METHODDEF \ |
| 12 | {"symtable", (PyCFunction)_symtable_symtable, METH_FASTCALL, _symtable_symtable__doc__}, |
| 13 | |
| 14 | static PyObject * |
| 15 | _symtable_symtable_impl(PyObject *module, const char *str, |
| 16 | PyObject *filename, const char *startstr); |
| 17 | |
| 18 | static PyObject * |
| 19 | _symtable_symtable(PyObject *module, PyObject **args, Py_ssize_t nargs, PyObject *kwnames) |
| 20 | { |
| 21 | PyObject *return_value = NULL; |
| 22 | const char *str; |
| 23 | PyObject *filename; |
| 24 | const char *startstr; |
| 25 | |
| 26 | if (!_PyArg_ParseStack(args, nargs, "sO&s:symtable", |
| 27 | &str, PyUnicode_FSDecoder, &filename, &startstr)) { |
| 28 | goto exit; |
| 29 | } |
| 30 | |
| 31 | if (!_PyArg_NoStackKeywords("symtable", kwnames)) { |
| 32 | goto exit; |
| 33 | } |
| 34 | return_value = _symtable_symtable_impl(module, str, filename, startstr); |
| 35 | |
| 36 | exit: |
| 37 | return return_value; |
| 38 | } |
| 39 | /*[clinic end generated code: output=071dee4d836e2cfd input=a9049054013a1b77]*/ |