#include #include int main() { typedef std::vector vec_t; typedef boost::sub_range range_t; vec_t vec(10); range_t r(vec.begin(), vec.end()); const range_t & r_ref = r; range_t v = r_ref; }