Author: mattip Branch: numpypy-out Changeset: r52531:e3b7e88090b8 Date: 2012-02-15 23:58 +0200 http://bitbucket.org/pypy/pypy/changeset/e3b7e88090b8/
Log: all pre-out_arg tests pass diff --git a/pypy/module/micronumpy/interp_numarray.py b/pypy/module/micronumpy/interp_numarray.py --- a/pypy/module/micronumpy/interp_numarray.py +++ b/pypy/module/micronumpy/interp_numarray.py @@ -723,7 +723,6 @@ raise NotImplementedError def compute(self): - assert isinstance(self.res, BaseArray) ra = ResultArray(self, self.size, self.shape, self.res_dtype, self.res) loop.compute(ra) @@ -799,8 +798,6 @@ out_arg=None): VirtualArray.__init__(self, name, shape, res_dtype, out_arg) self.ufunc = ufunc - assert isinstance(left, BaseArray) - assert isinstance(right, BaseArray) self.left = left self.right = right self.calc_dtype = calc_dtype @@ -813,6 +810,8 @@ def create_sig(self): if self.forced_result is not None: return self.forced_result.create_sig() + assert isinstance(self.left, BaseArray) + assert isinstance(self.right, BaseArray) if self.shape != self.left.shape and self.shape != self.right.shape: return signature.BroadcastBoth(self.ufunc, self.name, self.calc_dtype, @@ -835,6 +834,7 @@ def __init__(self, child, size, shape, dtype, res=None, order='C'): if res is None: res = W_NDimArray(size, shape, dtype, order) + assert isinstance(res, BaseArray) Call2.__init__(self, None, 'assign', shape, dtype, dtype, res, child) def create_sig(self): _______________________________________________ pypy-commit mailing list pypy-commit@python.org http://mail.python.org/mailman/listinfo/pypy-commit