summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorpierregm <pierregm@localhost>2009-12-07 20:28:09 +0000
committerpierregm <pierregm@localhost>2009-12-07 20:28:09 +0000
commit9fef44316518533cdfb6314b32fcbb015fa9f836 (patch)
treecc9744200cbe45bc48aeffd491714f029db575da
parentf5c5c6d3b1e7e090c3bdf92cf8139355993a1c06 (diff)
downloadnumpy-9fef44316518533cdfb6314b32fcbb015fa9f836.tar.gz
* Bugfix #1173 and #1174 (Michael D.)
-rw-r--r--numpy/ma/core.py1
-rw-r--r--numpy/ma/tests/test_core.py2
2 files changed, 2 insertions, 1 deletions
diff --git a/numpy/ma/core.py b/numpy/ma/core.py
index f28a5738e..a6cd94e44 100644
--- a/numpy/ma/core.py
+++ b/numpy/ma/core.py
@@ -854,6 +854,7 @@ class _MaskedUnaryOperation:
np.seterr(**err_status_ini)
# Make a mask
m = ~umath.isfinite(result)
+ m |= self.domain(d)
m |= getmask(a)
# Case 1.2. : Function without a domain
else:
diff --git a/numpy/ma/tests/test_core.py b/numpy/ma/tests/test_core.py
index db8034663..541c34589 100644
--- a/numpy/ma/tests/test_core.py
+++ b/numpy/ma/tests/test_core.py
@@ -1416,7 +1416,7 @@ class TestUfuncs(TestCase):
ur = uf(*args)
mr = mf(*args)
assert_equal(ur.filled(0), mr.filled(0), f)
- assert_mask_equal(ur.mask, mr.mask)
+ assert_mask_equal(ur.mask, mr.mask, err_msg=f)
#........................
def test_reduce(self):
"Tests reduce on MaskedArrays."