Previewing VS2015's Improved C++ Compliance
Microsoft’s Andrew Pardoe has provided a detailed walkthrough of the new C++ compiler improvements that are part of VS2015 Update 2. Keeping with overall theme of Update 2—code quality & stability-- C++ users will be happy to learn that roughly 300 bug fixes are coming. Developers should refer to the Breaking Changes list before applying Update 2 as code that currently compiles cleanly may no longer do so with the elimination of these compiler bugs.
Beyond bug fixes, Update 2 will bring the following changes for C++ developers:
constexpr– Not complete, but should see further progress from what is in Update 1.
- Variable templates – Visual C++ will now support template declarations for variables as well as the previously supported function, class, and alias.
- Order of initializer list – Initializer lists will be called in order as defined by the C++ standard.
- C++ Module – Improving support for C++ modules was introduced in Update 1 but not completely usable. Progress has been made so that it works better in Update 2.
- UTF-8 – New command-line options have been added so that developers can explicitly state the source character set (used in a program’s source code) and the execution character sets (used in a program’s execution environment).
Beyond the compiler improvements, Microsoft’s resident C++ guru Stephan T. Lavavej has updated the list of C++ Standard Template Library (STL) items that will be provided in VS2015 Update 2 (10 so far). Since C++17 has yet to be formally ratified and voted complete, there may be additional items for the compiler team to implement. Additionally, C99 Standard Library support is complete with the exception of tgmath.h and the pragma macros
FP_CONTRACT. That same list also includes the current Library Issues and the various releases of Visual Studio that address them. Importantly, Lavavej notes that users of Visual Studio Community Edition will also benefit from the STL additions—access to it will not be limited to the premium editions.