
14 Oct
2006
14 Oct
'06
1:02 a.m.
Hi, If a pointer container holds noncopyable objects, the iterators seem not to meet ReadableIteratorConcept whose 'value_type' must be CopyConstructible? This doesn't compile: #include <boost/ptr_container/ptr_vector.hpp> #include <boost/concept_check.hpp> #include <boost/iterator/iterator_concepts.hpp> #include <boost/noncopyable.hpp> struct my : boost::noncopyable { }; template< class Iterator > void foo(Iterator) { boost::function_requires< boost_concepts::ReadableIteratorConcept<Iterator> >(); } int main() { boost::ptr_vector<my> vec; ::foo(vec.begin()); } Anything wrong..? -- Shunsuke Sogame