When we announced that the Visual Studio 2010 Release Candidate Is Now Available For Download, a reader, Igor, asked us to provide a table summarizing which C++0x Core Language features are implemented in VC10. So, here it is! It’s derived from, but slightly modified from, GCC’s tables. For example, I added “Rvalue references v2”.
VC9 |
VC10 |
|
No |
v2 |
|
No |
v2 |
|
No |
No |
|
Yes |
Yes |
|
No |
Yes |
|
No |
Yes |
|
No |
Yes |
|
No |
Yes |
|
No |
Yes |
|
No |
v1.0 |
|
No |
Yes |
|
Yes |
Yes |
|
Yes |
Yes |
|
No |
Yes |
|
Partial |
Partial |
|
No |
No |
|
Partial |
Partial |
|
Yes |
Yes |
|
C++0x Core Language Features: Concurrency |
||
No |
Yes |
|
Partial |
Partial |
|
C++0x Core Language Features: C99 |
||
Partial |
Partial |
|
Partial |
Partial |
|
Yes |
Yes |
While I can’t explain all of these features here, I can link to my posts about lambdas v1.0, auto, and static_assert, rvalue references v1, and decltype, and I can decode some of the more mysterious cells in this table.
The difference between what I call “rvalue references v1” and “rvalue references v2” is that v1 allowed rvalue references to bind to lvalues, while v2 forbids this. N2844 “Fixing a Safety Problem with Rvalue References” describes the reasons for this change. It was recently voted into the C++0x Working Paper, and there was enough time for us to implement it in VC10. (Importantly, rvalue references v2 doesn’t affect the move semantics or perfect forwarding patterns, but it does affect the implementation of std::move() and std::forward<T>(), and experts need to know about this change.)
The difference between what I call “lambdas v1.0” and “lambdas v1.1” is much less significant. After lambdas were voted into the Working Paper and implemented in VC10, N2927 “New wording for C++0x Lambdas” was additionally voted into the Working Paper, clarifying subtleties like what happens with nested lambdas. Common uses of lambdas aren’t really affected, but unusual uses may be.
The “Partial” entries indicate that VC’s support is either incomplete (as in the case of the C99 preprocessor, where variadic macros are implemented but mixed narrow/wide string literal concatenation isn’t), or in a non-Standard form (as in the case of __func__, where __FUNCTION__ is implemented).
I don’t have a similar table for the C++0x Standard Library features implemented in VC10 (preparing one based on N2870 would take a while), but slides 28 and beyond of my BoostCon 2009 presentation (attached below) contain a useful summary.
Stephan T. Lavavej
Visual C++ Libraries Developer
(July 13, 2010 update: reformatted table, corrected “Forward declared enums” row.)
0 comments