diff options
author | Travis Oliphant <oliphant@enthought.com> | 2007-04-12 08:38:23 +0000 |
---|---|---|
committer | Travis Oliphant <oliphant@enthought.com> | 2007-04-12 08:38:23 +0000 |
commit | f78cdaf146aeb94f1d178972704d13005ea9c8f5 (patch) | |
tree | 3dcb0fdfd0dd24e27fd4aeeaed580c2b6418c02b | |
parent | 7cc1a819fe25368d1cc9a2ff56af950d6e300948 (diff) | |
download | numpy-f78cdaf146aeb94f1d178972704d13005ea9c8f5.tar.gz |
Fix scalar creation function so it can take sequences.
-rw-r--r-- | numpy/core/src/scalartypes.inc.src | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/numpy/core/src/scalartypes.inc.src b/numpy/core/src/scalartypes.inc.src index 2a2dffd6c..2eda10c12 100644 --- a/numpy/core/src/scalartypes.inc.src +++ b/numpy/core/src/scalartypes.inc.src @@ -1761,6 +1761,7 @@ static PyObject * } arr = PyArray_FromAny(obj, typecode, 0, 0, FORCECAST, NULL); + if ((arr==NULL) || (PyArray_NDIM(arr) > 0)) return arr; robj = PyArray_Return((PyArrayObject *)arr); finish: |