diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2016-07-23 20:47:26 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2016-07-23 20:47:26 +0000 |
commit | 51072bd6bf79ef2bc6a922079bff57c31c1effbc (patch) | |
tree | 91a2effbc9e6f80bdbbf9eb70e06c51ad0867ea0 /test/std/experimental/algorithms/alg.search | |
parent | bb5e33f003797b67974a8893f7f2930fc51b8210 (diff) |
Notes
Diffstat (limited to 'test/std/experimental/algorithms/alg.search')
-rw-r--r-- | test/std/experimental/algorithms/alg.search/search.pass.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/test/std/experimental/algorithms/alg.search/search.pass.cpp b/test/std/experimental/algorithms/alg.search/search.pass.cpp index 60a44e4c26a2..81d220ba1aed 100644 --- a/test/std/experimental/algorithms/alg.search/search.pass.cpp +++ b/test/std/experimental/algorithms/alg.search/search.pass.cpp @@ -15,7 +15,7 @@ // ForwardIterator search(ForwardIterator first, ForwardIterator last, // const Searcher& searcher); // -// returns searcher.operator(first, last) +// returns searcher.operator(first, last).first // #include <experimental/algorithm> @@ -27,10 +27,11 @@ int searcher_called = 0; struct MySearcher { template <typename Iterator> - Iterator operator() ( Iterator b, Iterator /*e*/) const + std::pair<Iterator, Iterator> + operator() (Iterator b, Iterator e) const { ++searcher_called; - return b; + return std::make_pair(b, e); } }; |