[Numpy-discussion] Boolean binary '-' operator
nathan12343 at gmail.com
Wed Jun 28 10:55:29 EDT 2017
Just as a comment: It would be really nice if NumPy could slow down the
pace of deprecations, or at least make the warnings about deprecations more
visible. It seems like every release breaks some subset of our test suite
(we only had one or two cases of using the binary - operator on boolean
arrays so it wasn't a big deal this time). For projects that don't have
resources for ongoing maintenance this is a recipe for bitrot...
On Wed, Jun 28, 2017 at 9:48 AM, Marten van Kerkwijk <
m.h.vankerkwijk at gmail.com> wrote:
> My two ¢: keep things as they are. There is just two much code that
> uses the C definition of bools, 0=False, 1=True. Coupled with casting
> every outcome that is unequal to 0 as True, * as AND, + as OR, and -
> as XOR makes sense (and -True would indeed be True, but I'm quite
> happy to have that one removed...).
> I lost track a little, but isn't this way also consistent with python,
> the one difference being that numpy does an implicit cast to bool on
> the result?
> -- Marten
> NumPy-Discussion mailing list
> NumPy-Discussion at python.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the NumPy-Discussion