summaryrefslogtreecommitdiff
path: root/numpy/array_api/tests/test_validation.py
diff options
context:
space:
mode:
authorSebastian Berg <sebastian@sipsolutions.net>2022-02-09 14:16:40 -0800
committerGitHub <noreply@github.com>2022-02-09 14:16:40 -0800
commitd7929b3722815eb261fba7ca03acf4f0d8d5f78e (patch)
tree42e3344b3adcbdf61f28192dc4fea58cea0a1f86 /numpy/array_api/tests/test_validation.py
parentf14591f1d1e1e12c7aff2a7f3f203a38a91db876 (diff)
downloadnumpy-d7929b3722815eb261fba7ca03acf4f0d8d5f78e.tar.gz
API: Disallow strings in logical ufuncs (#21024)
* API: Disallow strings in logical ufuncs This restores pre 1.22 NumPy behaviour for strings passed into logical ufuncs. Logical ufuncs should be able to cast inputs to booleans without modifying their results. Thus they do this now (in NumPy 1.22+). The problem is that string to bool casts are very strange in NumPy currently. This should be reverted/removed once string to bool casts are well defined. But until then, it seems more reasonable to just reject strings. Closes gh-20898 Co-authored-by: Ross Barnowski <rossbar@berkeley.edu>
Diffstat (limited to 'numpy/array_api/tests/test_validation.py')
0 files changed, 0 insertions, 0 deletions