
29 Jan
2005
29 Jan
'05
5:07 p.m.
Thorsten Ottosen wrote:
"Eric Niebler" <eric@boost-consulting.com> wrote in message news:41FAD566.6080001@boost-consulting.com... | | The following trivial use of Boost.Range fails to compile: | | #include <boost/range/begin.hpp> | | template<class Rng> | void foo(Rng const& rng) | { | boost::begin(rng); | } | | int main() | { | char* sz = "hello"; | foo( sz ); | }
Pavol recently the same problem. Our solution was to pass the char* arguments by value. That should be what the current CVS version does.
Are you sure? I just sync'ed, and the string versions of begin() and end() still take their arguments by reference. The problem remains. -- Eric Niebler Boost Consulting www.boost-consulting.com