-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add tests for more permissive any/all with non-boolean collections #18969
Conversation
Ah, found it, the change in |
so map and comprehensions are fine now? |
They don't short-circuit, otherwise yes. |
but calling |
Only if the result has function timeit()
t_any_some = Any[false; trues(10)]
t_any_many = Any[false; trues(1000000)]
t_bool = Bool[false; trues(1000000)]
res = map(all, (t_any_some, t_any_many, t_bool)) #compile
@time all(t_any_some)
@time all(t_any_many)
@time all(t_bool)
res
end julia> timeit()
0.000001 seconds
0.027037 seconds
0.000004 seconds
(false,false,false) |
Because of #19543, this is no longer valid as it is. What do?
|
The tests seem worth keeping |
Neat, thanks @tkelman! |
b055a1a
to
be4cedb
Compare
It is done. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm, thanks @fcard!
.