Opened 12 years ago
Closed 12 years ago
#5137 closed Bugs (fixed)
any_range : boost/range/concepts.hpp is missing
| Reported by: | Owned by: | Neil Groves | |
|---|---|---|---|
| Milestone: | To Be Determined | Component: | range |
| Version: | Boost Development Trunk | Severity: | Problem |
| Keywords: | Cc: |
Description
#include <boost/range/concepts.hpp>
needs to boost/range/any_range.hpp. tried code:
#include <vector>
#include <boost/assign/list_of.hpp>
//#include <boost/range/concepts.hpp>
#include <boost/range/any_range.hpp> // error! concept is nothing!
#include <boost/range/adaptor/filtered.hpp>
#include <boost/range/algorithm/for_each.hpp>
bool is_even(int x) { return x % 2 == 0; }
void disp(int x) { std::cout << x << std::endl; }
int main()
{
const std::vector<int> v = boost::assign::list_of(1)(2)(3)(4)(5);
boost::any_range<int, boost::forward_traversal_tag, const int&, ptrdiff_t> r = v | boost::adaptors::filtered(is_even);
boost::for_each(r, disp);
}
and, any_range template parameter is very many.
Change History (2)
comment:1 by , 12 years ago
comment:2 by , 12 years ago
| Resolution: | → fixed |
|---|---|
| Status: | new → closed |
Note:
See TracTickets
for help on using tickets.

sorry, compile successful in rev.68177.