Boost logo

Boost :

From: Eric Niebler (eric_at_[hidden])
Date: 2007-11-11 12:29:38


I got the code expansion wrong. Corrected version below.

Eric Niebler wrote:
> The above
> code expands to something like:
>
> typedef typename boost::result_of<
        Function (
> typename remove_reference<
> typename result_of::at_c<Sequence,0>::type
> >::type,
> typename remove_reference<
> typename result_of::at_c<Sequence,1>::type
> >::type,
> ...
        )
> >::type result_type;
>
> And I think it should be:
>
> typedef typename boost::result_of<
        Function (
> typename result_of::at_c<Sequence,0>::type,
> typename result_of::at_c<Sequence,1>::type
> ...
        )
> >::type result_type;
>
> I have a sequence where some elements are references and some are
> values. And I have a function object that treats references and values
> differently. So, why are top-level references being stripped here?

-- 
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