summaryrefslogtreecommitdiff
path: root/numpy/core/oldnumeric.py
diff options
context:
space:
mode:
Diffstat (limited to 'numpy/core/oldnumeric.py')
-rw-r--r--numpy/core/oldnumeric.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/numpy/core/oldnumeric.py b/numpy/core/oldnumeric.py
index e9d1835ac..978104469 100644
--- a/numpy/core/oldnumeric.py
+++ b/numpy/core/oldnumeric.py
@@ -167,6 +167,8 @@ def _wrapit(obj, method, *args, **kwds):
wrap = None
result = getattr(asarray(obj),method)(*args, **kwds)
if wrap:
+ if not isinstance(result, mu.ndarray):
+ result = asarray(result)
result = wrap(result)
return result