Mark Dickinson <dicki...@gmail.com> added the comment: > This one is common to both python bool and np.bool_.
It's not, though. One of my examples was using `~` (`__invert__`) from the proposed ABC). And the behaviour of that function differs between NumPy and Python I think one of the rules about this sort of abstraction should be that there should be multiple concrete examples available that you intend the abstraction to apply to, *before* you abstract. Otherwise there's a risk of making an abstraction that doesn't turn out to fit actual use-cases. Right now, we only have Python's bool as a concrete example; NumPy's bool_ is IMO not close enough in its behaviour. Are you aware of other bool-like types around that the proposed ABC would be helpful for? ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue32886> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com