diff options
author | Sebastian Berg <sebastian@sipsolutions.net> | 2013-04-20 23:48:13 +0200 |
---|---|---|
committer | Sebastian Berg <sebastian@sipsolutions.net> | 2013-05-31 19:16:02 +0200 |
commit | c51f2549e824f4e8bcee550d993fe6a1ced9cacb (patch) | |
tree | 66213a5ff21e9f5dee310a5a3a1653e0e47657bf /numpy | |
parent | 399e55bd41081555e4fc93d567a478fc576cdd00 (diff) | |
download | numpy-c51f2549e824f4e8bcee550d993fe6a1ced9cacb.tar.gz |
STY: style and small doc fixes for integer deprecations
Diffstat (limited to 'numpy')
-rw-r--r-- | numpy/core/src/multiarray/conversion_utils.c | 7 | ||||
-rw-r--r-- | numpy/core/src/multiarray/number.c | 4 |
2 files changed, 7 insertions, 4 deletions
diff --git a/numpy/core/src/multiarray/conversion_utils.c b/numpy/core/src/multiarray/conversion_utils.c index 71690c20b..3ea5957b9 100644 --- a/numpy/core/src/multiarray/conversion_utils.c +++ b/numpy/core/src/multiarray/conversion_utils.c @@ -96,13 +96,16 @@ PyArray_IntpConverter(PyObject *obj, PyArray_Dims *seq) if (len == -1) { /* Check to see if it is an integer number */ if (PyNumber_Check(obj)) { - /* DEPRECATED: replace PyNumber_Check with PyIndex_Check */ + /* + * After the deprecation the PyNumber_Check could be replaced + * by PyIndex_Check. + */ len = 1; } } if (len < 0) { PyErr_SetString(PyExc_TypeError, - "expected sequence object with len >= 0 or a single integer"); + "expected sequence object with len >= 0 or a single integer"); return NPY_FAIL; } if (len > NPY_MAXDIMS) { diff --git a/numpy/core/src/multiarray/number.c b/numpy/core/src/multiarray/number.c index 53218117a..9e13d0f29 100644 --- a/numpy/core/src/multiarray/number.c +++ b/numpy/core/src/multiarray/number.c @@ -841,8 +841,8 @@ array_index(PyArrayObject *v) return NULL; } if (PyArray_NDIM(v) != 0) { - if (DEPRECATE("converting an array with ndim > 0 to an index" - " will result in an error in the future") < 0) { + if (DEPRECATE("converting an array with ndim > 0 to an index" + " will result in an error in the future") < 0) { return NULL; } } |