Boost logo

Boost :

From: Giovanni Piero Deretta (gpderetta_at_[hidden])
Date: 2008-06-24 13:19:10


On Tue, Jun 24, 2008 at 7:07 PM, Daniel Walker
<daniel.j.walker_at_[hidden]> wrote:
> On Tue, Jun 24, 2008 at 12:51 PM, Daniel Walker
> <daniel.j.walker_at_[hidden]> wrote:
>> On Tue, Jun 24, 2008 at 12:12 PM, Mathias Gaunard
>> <mathias.gaunard_at_[hidden]> wrote:
>>> Steven Watanabe wrote:
>>>> Can't you use result_of?
>>>
>>> As far as I can see, the current boost::result_of implementation doesn't
>>> use decltype or typeof.
>>
>> The boost::result_of on svn trunk uses decltype when
>> BOOST_HAS_DECLTYPE is defined. This happens automatically for gcc
>> versions after 4.2.
>
> Correction - for gcc > 4.2, the boost::result_of on svn trunk uses
> decltype only when you compile with -std=c++0x. It uses the old TR1
> heuristic otherwise.
>

"__decltype()" works even outside of C++0x mode. Shouldn't it be used instead?

-- 
gpd

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk