diff options
author | Travis Oliphant <oliphant@enthought.com> | 2006-03-24 19:16:04 +0000 |
---|---|---|
committer | Travis Oliphant <oliphant@enthought.com> | 2006-03-24 19:16:04 +0000 |
commit | 76612bfed9caef1f619c12bdd867b4974e93d8f4 (patch) | |
tree | fb31ec0b17563f1314dc4464d5d3e23d95bf840c /numpy/core | |
parent | 4bd0d90ed1786edf87e7939258026b35099a9a80 (diff) | |
download | numpy-76612bfed9caef1f619c12bdd867b4974e93d8f4.tar.gz |
Simplify interfaces. Fix UCHAR bug.
Diffstat (limited to 'numpy/core')
-rw-r--r-- | numpy/core/include/numpy/arrayobject.h | 2 | ||||
-rw-r--r-- | numpy/core/numeric.py | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/numpy/core/include/numpy/arrayobject.h b/numpy/core/include/numpy/arrayobject.h index 797966a25..a301a8a1b 100644 --- a/numpy/core/include/numpy/arrayobject.h +++ b/numpy/core/include/numpy/arrayobject.h @@ -1303,7 +1303,7 @@ typedef struct { #define PyTypeNum_ISNUMBER(type) (type <= PyArray_CLONGDOUBLE) -#define PyTypeNum_ISSTRING(type) ((type == PyArray_UCHAR) || \ +#define PyTypeNum_ISSTRING(type) ((type == PyArray_STRING) || \ (type == PyArray_UNICODE)) #define PyTypeNum_ISCOMPLEX(type) ((type >= PyArray_CFLOAT) && \ diff --git a/numpy/core/numeric.py b/numpy/core/numeric.py index 689e5c733..630f9ff66 100644 --- a/numpy/core/numeric.py +++ b/numpy/core/numeric.py @@ -108,17 +108,17 @@ can_cast = multiarray.can_cast lexsort = multiarray.lexsort -def asarray(a, dtype=None, fortran=None, ndmin=0): +def asarray(a, dtype=None, fortran=None): """returns a as an array. Unlike array(), no copy is performed if a is already an array. Subclasses are converted to base class ndarray. """ - return array(a, dtype, copy=False, fortran=fortran, ndmin=ndmin) + return array(a, dtype, copy=False, fortran=fortran) -def asanyarray(a, dtype=None, copy=False, fortran=None, ndmin=0): +def asanyarray(a, dtype=None, copy=False, fortran=None): """will pass subclasses through... """ - return array(a, dtype, copy=copy, fortran=fortran, subok=1, ndmin=ndmin) + return array(a, dtype, copy=copy, fortran=fortran, subok=1) def ascontiguous(a, dtype=None, copy=False): return array(a, dtype, copy=copy, fortran=False, ndmin=1) |