|
Boost : |
From: Eric Niebler (eric_at_[hidden])
Date: 2005-01-29 12:07:17
Thorsten Ottosen wrote:
> "Eric Niebler" <eric_at_[hidden]> wrote in message
> news:41FAD566.6080001_at_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
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk