Boost logo

Boost Users :

Subject: Re: [Boost-users] BOOST_RESULT_OF_USE_DECLTYPE not default on C++11 compilers
From: Philipp Moeller (philipp.moeller_at_[hidden])
Date: 2012-01-26 05:09:31


Jeremiah Willcock <jewillco_at_[hidden]> writes:

> At least on GCC 4.6 in C++0x (C++11) mode,
> BOOST_RESULT_OF_USE_DECLTYPE is not set by default, preventing classes
> such as boost::transform_iterator from working on built-in lambda
> expressions. Is there a reason that the use of decltype is not on by
> default for compilers that support it, perhaps with a flag to force
> emulation mode (like Boost.Move supports)?
>
> -- Jeremiah Willcock
>

I noticed the same. Although gcc's decltype has been partially broken,
at least on gcc, and can sometimes have strange effects when used with
`result_of`. (I think this actually used to be a bug in the draft.) This
situation would have to be resolved in Boost.Config or with a
`result_of` specific solution.

-- 
Philipp Moeller

Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net