diff options
Diffstat (limited to 'numpy/core/src')
-rw-r--r-- | numpy/core/src/multiarray/descriptor.c | 7 | ||||
-rw-r--r-- | numpy/core/src/scalarmathmodule.c.src | 4 |
2 files changed, 4 insertions, 7 deletions
diff --git a/numpy/core/src/multiarray/descriptor.c b/numpy/core/src/multiarray/descriptor.c index 3cc2f28ac..10b93d3dd 100644 --- a/numpy/core/src/multiarray/descriptor.c +++ b/numpy/core/src/multiarray/descriptor.c @@ -1629,7 +1629,7 @@ arraydescr_typename_get(PyArray_Descr *self) { int len; PyTypeObject *typeobj = self->typeobj; - PyObject *res, *tmp; + PyObject *res; char *s; /* fixme: not reentrant */ static int prefix_len = 0; @@ -2800,10 +2800,9 @@ descr_subscript(PyArray_Descr *self, PyObject *op) PyObject *retval; if (!self->names) { - PyObject *astr, *bstr; - astr = arraydescr_str(self); + PyObject *astr = arraydescr_str(self); #if defined(NPY_PY3K) - bstr = PyUnicode_AsUnicodeEscapeString(astr); + PyObject *bstr = PyUnicode_AsUnicodeEscapeString(astr); Py_DECREF(astr); astr = bstr; #endif diff --git a/numpy/core/src/scalarmathmodule.c.src b/numpy/core/src/scalarmathmodule.c.src index 5ab720bb0..d5475a30b 100644 --- a/numpy/core/src/scalarmathmodule.c.src +++ b/numpy/core/src/scalarmathmodule.c.src @@ -1490,10 +1490,8 @@ PyMODINIT_FUNC initscalarmath(void) #endif { - PyObject *m; - #if defined(NPY_PY3K) - m = PyModule_Create(&moduledef); + PyObject *m = PyModule_Create(&moduledef); if (!m) { return NULL; } |