Boost logo

Boost :

Subject: Re: [boost] [result_of] Test fails on clang trunk and gcc-4.7 due to changes in FDIS
From: Eric Niebler (eric_at_[hidden])
Date: 2012-03-28 12:09:16


On 3/28/2012 4:39 AM, Michel Morin wrote:
> In the code below,
>
> const int f(); decltype(f()) i = 0;
>
> `i` has type `int` (not `const int`) in C++11. This is because
> `f()` is a prvalue of a non-class type (i.e. `const int`) and so
> its cv qualifiers are ignored.
>
> C++0x drafts (before FDIS) had a special rule for function calls in
> decltype: if e is a function call or an invocation of an overloaded
> operator (parentheses around e are ignored), decltype(e) is the
> return type of the statically chosen function; but this was removed
> in FDIS.
<snip>

That wording should still be FDIS. That's decltype v1.1 that Stephan
was referring to in the other result_of thread you've discussed.

-- 
Eric Niebler
BoostPro Computing
http://www.boostpro.com

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