|
Boost : |
Subject: Re: [boost] [fusion] pop_back doesn't work on fwd sequences
From: Joel de Guzman (joel_at_[hidden])
Date: 2011-08-11 21:24:08
On 8/12/2011 9:08 AM, Eric Niebler wrote:
> I wanted to test this, so I tried the following:
>
> using namespace boost::fusion;
> auto vec = make_vector(1, 3.14, "hello");
> auto push = push_back(vec, 42);
> auto pop = pop_back(push);
>
> auto i1 = find<int>(pop);
> auto i2 = find<double>(pop);
>
> assert(i1 != end(pop));
> assert(i2 != end(pop));
> assert(i1 != i2);
>
> It doesn't compile for me. I think it should. And I would hope none of
> the asserts fire. Will that be the case?
I think so. It's most probably a bug in the implementation. I'll go
check it out.
Regards,
-- Joel de Guzman http://www.boostpro.com http://boost-spirit.com
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk