comparison Python/Python-ast.c @ 66261:d22aa5ae7762 3.1

Merged revisions 86545 via svnmerge from svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r86545 | benjamin.peterson | 2010-11-19 22:31:07 -0600 (Fri, 19 Nov 2010) | 1 line new plan: functions that want 'tmp' can declare it ........
author Benjamin Peterson <benjamin@python.org>
date Sat, 20 Nov 2010 04:37:00 +0000
parents 51f72c5fe28e
children 3c9232a684ae
comparison
equal deleted inserted replaced
66258:4572d28dbac7 66261:d22aa5ae7762
3376 3376
3377 3377
3378 int 3378 int
3379 obj2ast_mod(PyObject* obj, mod_ty* out, PyArena* arena) 3379 obj2ast_mod(PyObject* obj, mod_ty* out, PyArena* arena)
3380 { 3380 {
3381 PyObject* tmp = NULL;
3382 int isinstance; 3381 int isinstance;
3383 tmp = tmp; 3382
3384 3383 PyObject *tmp = NULL;
3385 3384
3386 if (obj == Py_None) { 3385 if (obj == Py_None) {
3387 *out = NULL; 3386 *out = NULL;
3388 return 0; 3387 return 0;
3389 } 3388 }
3525 } 3524 }
3526 3525
3527 int 3526 int
3528 obj2ast_stmt(PyObject* obj, stmt_ty* out, PyArena* arena) 3527 obj2ast_stmt(PyObject* obj, stmt_ty* out, PyArena* arena)
3529 { 3528 {
3530 PyObject* tmp = NULL;
3531 int isinstance; 3529 int isinstance;
3532 tmp = tmp; 3530
3533 3531 PyObject *tmp = NULL;
3534 int lineno; 3532 int lineno;
3535 int col_offset; 3533 int col_offset;
3536 3534
3537 if (obj == Py_None) { 3535 if (obj == Py_None) {
3538 *out = NULL; 3536 *out = NULL;
4722 } 4720 }
4723 4721
4724 int 4722 int
4725 obj2ast_expr(PyObject* obj, expr_ty* out, PyArena* arena) 4723 obj2ast_expr(PyObject* obj, expr_ty* out, PyArena* arena)
4726 { 4724 {
4727 PyObject* tmp = NULL;
4728 int isinstance; 4725 int isinstance;
4729 tmp = tmp; 4726
4730 4727 PyObject *tmp = NULL;
4731 int lineno; 4728 int lineno;
4732 int col_offset; 4729 int col_offset;
4733 4730
4734 if (obj == Py_None) { 4731 if (obj == Py_None) {
4735 *out = NULL; 4732 *out = NULL;
5838 } 5835 }
5839 5836
5840 int 5837 int
5841 obj2ast_expr_context(PyObject* obj, expr_context_ty* out, PyArena* arena) 5838 obj2ast_expr_context(PyObject* obj, expr_context_ty* out, PyArena* arena)
5842 { 5839 {
5843 PyObject* tmp = NULL;
5844 int isinstance; 5840 int isinstance;
5845 tmp = tmp;
5846 5841
5847 isinstance = PyObject_IsInstance(obj, (PyObject *)Load_type); 5842 isinstance = PyObject_IsInstance(obj, (PyObject *)Load_type);
5848 if (isinstance == -1) { 5843 if (isinstance == -1) {
5849 return 1; 5844 return 1;
5850 } 5845 }
5898 } 5893 }
5899 5894
5900 int 5895 int
5901 obj2ast_slice(PyObject* obj, slice_ty* out, PyArena* arena) 5896 obj2ast_slice(PyObject* obj, slice_ty* out, PyArena* arena)
5902 { 5897 {
5903 PyObject* tmp = NULL;
5904 int isinstance; 5898 int isinstance;
5905 tmp = tmp; 5899
5906 5900 PyObject *tmp = NULL;
5907 5901
5908 if (obj == Py_None) { 5902 if (obj == Py_None) {
5909 *out = NULL; 5903 *out = NULL;
5910 return 0; 5904 return 0;
5911 } 5905 }
6021 } 6015 }
6022 6016
6023 int 6017 int
6024 obj2ast_boolop(PyObject* obj, boolop_ty* out, PyArena* arena) 6018 obj2ast_boolop(PyObject* obj, boolop_ty* out, PyArena* arena)
6025 { 6019 {
6026 PyObject* tmp = NULL;
6027 int isinstance; 6020 int isinstance;
6028 tmp = tmp;
6029 6021
6030 isinstance = PyObject_IsInstance(obj, (PyObject *)And_type); 6022 isinstance = PyObject_IsInstance(obj, (PyObject *)And_type);
6031 if (isinstance == -1) { 6023 if (isinstance == -1) {
6032 return 1; 6024 return 1;
6033 } 6025 }
6049 } 6041 }
6050 6042
6051 int 6043 int
6052 obj2ast_operator(PyObject* obj, operator_ty* out, PyArena* arena) 6044 obj2ast_operator(PyObject* obj, operator_ty* out, PyArena* arena)
6053 { 6045 {
6054 PyObject* tmp = NULL;
6055 int isinstance; 6046 int isinstance;
6056 tmp = tmp;
6057 6047
6058 isinstance = PyObject_IsInstance(obj, (PyObject *)Add_type); 6048 isinstance = PyObject_IsInstance(obj, (PyObject *)Add_type);
6059 if (isinstance == -1) { 6049 if (isinstance == -1) {
6060 return 1; 6050 return 1;
6061 } 6051 }
6157 } 6147 }
6158 6148
6159 int 6149 int
6160 obj2ast_unaryop(PyObject* obj, unaryop_ty* out, PyArena* arena) 6150 obj2ast_unaryop(PyObject* obj, unaryop_ty* out, PyArena* arena)
6161 { 6151 {
6162 PyObject* tmp = NULL;
6163 int isinstance; 6152 int isinstance;
6164 tmp = tmp;
6165 6153
6166 isinstance = PyObject_IsInstance(obj, (PyObject *)Invert_type); 6154 isinstance = PyObject_IsInstance(obj, (PyObject *)Invert_type);
6167 if (isinstance == -1) { 6155 if (isinstance == -1) {
6168 return 1; 6156 return 1;
6169 } 6157 }
6201 } 6189 }
6202 6190
6203 int 6191 int
6204 obj2ast_cmpop(PyObject* obj, cmpop_ty* out, PyArena* arena) 6192 obj2ast_cmpop(PyObject* obj, cmpop_ty* out, PyArena* arena)
6205 { 6193 {
6206 PyObject* tmp = NULL;
6207 int isinstance; 6194 int isinstance;
6208 tmp = tmp;
6209 6195
6210 isinstance = PyObject_IsInstance(obj, (PyObject *)Eq_type); 6196 isinstance = PyObject_IsInstance(obj, (PyObject *)Eq_type);
6211 if (isinstance == -1) { 6197 if (isinstance == -1) {
6212 return 1; 6198 return 1;
6213 } 6199 }
6357 } 6343 }
6358 6344
6359 int 6345 int
6360 obj2ast_excepthandler(PyObject* obj, excepthandler_ty* out, PyArena* arena) 6346 obj2ast_excepthandler(PyObject* obj, excepthandler_ty* out, PyArena* arena)
6361 { 6347 {
6362 PyObject* tmp = NULL;
6363 int isinstance; 6348 int isinstance;
6364 tmp = tmp; 6349
6365 6350 PyObject *tmp = NULL;
6366 int lineno; 6351 int lineno;
6367 int col_offset; 6352 int col_offset;
6368 6353
6369 if (obj == Py_None) { 6354 if (obj == Py_None) {
6370 *out = NULL; 6355 *out = NULL;