C++ Team Blog
The latest in C++, Visual Studio, VS Code, and vcpkg from the MSFT C++ team
Latest posts
An Update on C++/CLI and .NET Core
The first public release of our C++/CLI support for .NET Core 3.1 is now available for public preview! It is included in Visual Studio 2019 update 16.4 Preview 2. We would love it if you could try it out and send us any feedback you have. For more info about what this is and the roadmap going forward, check out my last post on the future of C++/CLI and .NET Core. To get started make sure you have all the necessary components installed. C++/CLI support for desktop development is an optional component, so you will need to select it on the installer’s right pane: You will also need the .NET Core cross-plat...
Microsoft C++ Team At CppCon 2019: Videos Available
Last month a large contingent from the Microsoft C++ team attended CppCon. We gave fourteen presentations covering our tools, developments in the standard, concepts which underlie the work we do, and more. We also recorded an episode of CppCast with Microsoft MVPs Rob Irving and Jason Turner. You can hear more about the Open Sourcing of MSVC's STL, the upcoming ASAN support in Visual Studio and our team's effort in achieving C++17 standards conformance. All our CppCon videos are available now, so please give them a watch and let us know what you think! ...
AddressSanitizer (ASan) for Windows with MSVC
⌚ This post was last updated on March 24th, 2021 with the latest information on ASan support. Note: This feature is now generally available. To get started, take a look at the official AddressSanitizer for Windows with MSVC documentation. Many experience improvements have been made since this blog post was published, and our docs have the latest information. We are pleased to announce AddressSanitizer (ASan) support for the MSVC toolset. ASan is a fast memory error detector that can find runtime memory issues such as use-after-free and perform out of bounds checks. Support for sanitizers has been ...
Usability Improvements for CMake in Visual Studio 2019 version 16.4: Launch Target Selection and Overview Pages
We hear your feedback, and in Visual Studio 2019 version 16.4 Preview 2 we have addressed one of our top Developer Community issues related to CMake development in Visual Studio by revamping the selection of CMake launch targets. We have also added Overview Pages for CMake to help you get started with CMake and cross-platform development. If you’re not familiar with Visual Studio's CMake support, be sure to check our CMake Support in Visual Studio introductory page. Launch Target Selection In Visual Studio 2019 you can select a CMake target to run via the launch drop-down menu: With Visual Studio 2019 ve...
Code analysis with clang-tidy in Visual Studio
[Updated on 11/6/2019] - Removed "Setup: Installing Clang tools" section; this is no longer required starting in Visual Studio 2019 version 16.4 Preview 3. Visual Studio 2019 version 16.4 Preview 1 brings a significant improvement to the C++ code analysis experience: native support for clang-tidy, a Clang-based “linter” tool developed by the LLVM Project that delivers a variety of code improvements such as modernization and standards conformance, static analysis, and automatic formatting. For more information about using Clang/LLVM as a compiler in your project, see our past blog posts on Clang/LLVM for MSBuil...
C++20’s Conditionally Explicit Constructors
is a C++20 feature for simplifying the implementation of generic types and improving compile-time performance. In C++ it is common to write and use types which wrap objects of other types. and are two examples, but there are plenty of others in the standard library, Boost, and likely your own codebases. Following the principle of least astonishment, it pays to ensure that these wrappers preserve the behavior of their stored types as much as is reasonable. Take as an example. It allows implicit conversion from a string literal, but not from a : This is achieved in by marking the constructor which tak...
Microsoft C++ Team on CppCast
Today we have a short guest post from Rob Irving, host of CppCast to tell us about an episode he recorded with our team. During CppCon 2019 the hosts of CppCast had a chance to sit down with Marian Luparu, Sy Brand and Stephan T. Lavavej from Microsoft's C++ team to discuss some of the announcements made by the team at CppCon. For those not familiar with CppCast. It's an audio podcast hosted by Microsoft MVPs Rob Irving and Jason Turner. This latest episode is the 216th of the (almost) weekly podcast that started in 2015. In each ~40-60 minute episode they talk to a member of the C++ community...
The Future of C++/CLI and .NET Core 3
.NET Core 3.0 is now available and we have received a lot of questions about what that means for the future of C++/CLI. First, we would like to let everyone know that we are committed to supporting C++/CLI for .NET Core to enable easy interop between C++ codebases and .NET technologies such as WPF and Windows Forms. This support isn’t going to be ready when .NET Core 3.0 first ships, but it will be available in .NET Core 3.1 which ships with Visual Studio 2019 16.4 – roadmap. C++/CLI will have full IDE support for targeting .NET Core 3.1 and higher. This support will include projects, IntelliSense, and mixed-m...
Open Sourcing MSVC’s STL
Today at CppCon 2019, we (the MSVC team) announced that we're releasing our implementation of the C++ Standard Library (also known as the STL) as open source. https://github.com/microsoft/STL is our new repository, containing all of our product source code, a new CMake build system, and a README with more information. As it explains, we're still working on migrating to GitHub. While you can clone and build the code right now, there are several things we need to do (like adding our test suites) before we can begin reviewing pull requests. Q&A Q: Why are you doing this? A: There are several reasons....