Skip to content

Commit

Permalink
Merge pull request #1878 from WalterBright/fix11973
Browse files Browse the repository at this point in the history
fix Issue 11973 - Please use any instead
  • Loading branch information
andralex committed Jan 25, 2014
2 parents 31a5813 + 7e458cc commit bcf2be7
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions std/algorithm.d
Original file line number Diff line number Diff line change
Expand Up @@ -10950,8 +10950,12 @@ was succesful.
+/
template canFind(alias pred="a == b")
{
//Explictly Undocumented. It will be removed in December 2014.
deprecated("Please use any instead.") bool canFind(Range)(Range haystack)
/++
Returns $(D true) if and only if any value $(D v) found in the
input range $(D range) satisfies the predicate $(D pred).
Performs (at most) $(BIGOH r.length) evaluations of $(D pred).
+/
bool canFind(Range)(Range haystack)
if (is(typeof(find!pred(haystack))))
{
return any!pred(haystack);
Expand Down

0 comments on commit bcf2be7

Please sign in to comment.