diff options
author | Travis Oliphant <oliphant@enthought.com> | 2006-07-19 03:33:22 +0000 |
---|---|---|
committer | Travis Oliphant <oliphant@enthought.com> | 2006-07-19 03:33:22 +0000 |
commit | 48ef07dc880e384409024c81e7da67cc47c90d9e (patch) | |
tree | 80b7ce4bc3777ac13218a2a2f38234d67649e84e /numpy/core/defmatrix.py | |
parent | d5a13c5e4d881a205bef6ce64cb2222aef98d43c (diff) | |
download | numpy-48ef07dc880e384409024c81e7da67cc47c90d9e.tar.gz |
Fix a couple of issues with object matrices
Diffstat (limited to 'numpy/core/defmatrix.py')
-rw-r--r-- | numpy/core/defmatrix.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/numpy/core/defmatrix.py b/numpy/core/defmatrix.py index bfcb68364..441500c90 100644 --- a/numpy/core/defmatrix.py +++ b/numpy/core/defmatrix.py @@ -122,6 +122,8 @@ class matrix(N.ndarray): def __getitem__(self, index): out = N.ndarray.__getitem__(self, index) + if not isinstance(out, matrix): + return out # Need to swap if slice is on first index # or there is an integer on the second retscal = False |