Closed
Description
This issue was originally filed by @seaneagan
If we had:
typedef bool Predicate<T>(T item);
interface Matcher<T> extends Predicate<T> {...}
instead of Matcher#matches, thus using "operator call", then the following would work:
collection.some(same(value));
collection.every(isNotNull);
collection.filter(isPositive);
Also, issue #2949 could be solved with:
switch(x) {
match (isNegative) ...
case (0) ...
match (lessThan(5)) ...
// avoid full blown Matcher since don't need mismatch messages
match ((i) => i.isEven()) ...
default ...
}