Visual Studio 2008 with c++11
In short words, it's impossible. VS2008 has no C++11 support and replacing the libraries would lead to chaos.
In long words, you maybe could do something:
- Use another compiler: C++ compiler support (Updated Link)
- You could upgrade your visual studio, but even MSVC12 (visual studio 2013) is not supporting all of C++11 standard.
- You could embed the Intel compiler into your visual studio. But also Intel is not fully supporting C++11, nevertheless more than MSVC. Here (Updated link now provides a general description) a small howto embed the Intel compiler.
- Update: clang is now also able to be used with visual studio, see here.
- Update: As Melebius stated in the comments, MSVC19 (VS2015) finally supports most of the C++11 standard... Support For C++11/14/17 Features (Modern C++)
If you're stuck using MSVC 2008 or 2010, I've managed to implement various C++11 (and some possibly-C++14) features for it as part of my cxxomfort backports library. Of course features that rely on lexer/parser support (such as variadic templates) can not be emulated, but for the most part it allows me to write forwards-compatible code in MSVC 2008 Express (my main Windows target).
However the idea would be that you use another compiler. There's GCC support for about as hight as 4.6 for Windows XP (via eg.: Mingw installer), and it brings about most of the important C++11 niceties such as variadic templates and constexpr
, noexcept
.