We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
KleeneValue
any_*
1 parent 28aa436 commit efb76cbCopy full SHA for efb76cb
servo/components/selectors/kleene_value.rs
@@ -38,6 +38,7 @@ impl KleeneValue {
38
39
/// Return true if any result of f() is true. Otherwise, return the strongest value seen.
40
/// Returns false if empty, like that of `Iterator`.
41
+ #[inline(always)]
42
pub fn any<T>(
43
iter: impl Iterator<Item = T>,
44
f: impl FnMut(T) -> Self,
@@ -47,13 +48,15 @@ impl KleeneValue {
47
48
49
/// Return false if any results of f() is false. Otherwise, return the strongest value seen.
50
/// Returns true if empty, opposite of `Iterator`.
51
52
pub fn any_false<T>(
53
54
55
) -> Self {
56
Self::any_value(iter, Self::False, Self::True, f)
57
}
58
59
60
fn any_value<T>(
61
62
value: Self,
0 commit comments