Boost logo

Boost :

Subject: Re: [boost] [config] vc10 and BOOST_NO_DECLTYPE
From: Anthony Williams (anthony.ajw_at_[hidden])
Date: 2010-04-06 18:03:24


Eric Niebler <eric_at_[hidden]> writes:

> On 4/6/2010 12:28 PM, Christophe Henry wrote:
>> I start having a bit of experience with decltype and VC compilers
>> (sigh) through my eUML front-end for MSM and I can give you one
>> reason: because it's probably not just VC10. I have here and there
>> this problem (and others) with VC9 too. It might just happen in
>> different conditions.
>
> This is NOT the same issue. VC9 does not have the decltype
> keyword. We're not talking about typeof emulation. Please don't take
> us off-topic.
>
> The issue is whether the decltype keyword is too broken on VC10 to
> define BOOST_NO_DECLTYPE. I think it /may/ be, so we should define it
> just to be safe, at least for 1.43.

I agree. There's more than one bug in VC10's implementation of
decltype. The following directly impacts result_of:

https://connect.microsoft.com/VisualStudio/feedback/details/541365/decltype-yields-incorrect-results-for-function-return-types-if-type-has-a-user-defined-constructor?wa=wsignin1.0

Note the comment by Jon Caves that this won't be fixed in the VC10 release.

Anthony

-- 
Author of C++ Concurrency in Action     http://www.stdthread.co.uk/book/
just::thread C++0x thread library             http://www.stdthread.co.uk
Just Software Solutions Ltd       http://www.justsoftwaresolutions.co.uk
15 Carrallack Mews, St Just, Cornwall, TR19 7UL, UK. Company No. 5478976

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