8000 MAINT: Removed 'if' block which served no purpose in core.py and remo… · numpy/numpy@beacb39 · GitHub
[go: up one dir, main page]

Skip to content

Commit beacb39

Browse files
committed
MAINT: Removed 'if' block which served no purpose in core.py and removed '_linalgRealType(t)' function from linalg.py
1 parent b30318a commit beacb39

File tree

2 files changed

+0
-11
lines changed

2 files changed

+0
-11
lines changed

numpy/linalg/linalg.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -128,10 +128,6 @@ def _realType(t, default=double):
128128
def _complexType(t, default=cdouble):
129129
return _complex_types_map.get(t, default)
130130

131-
def _linalgRealType(t):
132-
"""Cast the type t to either double or cdouble."""
133-
return double
134-
135131
def _commonType(*arrays):
136132
# in lite version, use higher precision (always double or cdouble)
137133
result_type = single

numpy/ma/core.py

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2839,13 +2839,6 @@ def __new__(cls, data=None, mask=nomask, dtype=None, copy=False,
28392839
_data = ndarray.view(_data, type(data))
28402840
else:
28412841
_data = ndarray.view(_data, cls)
2842-
# Backwards compatibility w/ numpy.core.ma.
2843-
if hasattr(data, '_mask') and not isinstance(data, ndarray):
2844-
_data._mask = data._mask
2845-
# FIXME: should we set `_data._sharedmask = True`?
2846-
# Previously this set `_sharedmask = True`, but
2847-
# that didn't actually do anything as the variable was unused!
2848-
28492842
# Process mask.
28502843
# Type of the mask
28512844
mdtype = make_mask_descr(_data.dtype)

0 commit comments

Comments
 (0)
0