C++ Team Blog

C++ tutorials, C and C++ news, and information about Visual Studio, Visual Studio Code, and Vcpkg from the Microsoft C++ team.

Build and Debug C++ with WSL 2 Distributions and Visual Studio 2022
Build and Debug C++ with WSL 2 Distributions and Visual Studio 2022
Visual Studio 2022 introduces a native WSL 2 toolset for C++ development. This toolset is available now in Visual Studio 2022 version 17.0 Preview 2. WSL 2 is the new, recommended version of the Windows Subsystem for Linux (WSL) architecture that provides better Linux file system performance, GUI support, and full system call compatibility. ...
Code Scanning C++ with GitHub Actions
Code Scanning C++ with GitHub Actions
Last year, GitHub released code scanning, which enables developers to incorporate security checks into their CI/CD environment and developer workflow. This post demonstrates the basics of using CodeQL, the analysis engine behind code scanning, with GitHub Actions. What is CodeQL? CodeQL is an analysis engine that automates security checks by...
Customized Warning Levels and Code Analysis for External Headers
Customized Warning Levels and Code Analysis for External Headers
If you have tried to keep your code clean by selecting strict compiler warning levels or code analysis rulesets, you likely know how frustrating it can be to see these warnings for headers that are not part of your project. To alleviate this, we’ve made it easy to mark headers as external to your project in the latest preview Visual Studio ...
STL Visualizers on GitHub
STL Visualizers on GitHub
We are happy to announce that now it’s possible to contribute to the STL Visualizers for Visual Studio's debugger on GitHub. A visualizer is a file with .natvis extension that allows you to manipulate the way native types appear in the debugger's watch window.  We've been working on fixing existing issues with the visualizers ...
Address Sanitizer Now in “Early Release” for Xbox Developers
Address Sanitizer Now in “Early Release” for Xbox Developers
Address Sanitizer is now available on Xbox, developers can leverage this powerful technology to help debug memory issues in their titles.  Combined with the crash dump changes detailed here, it should provide all the flexibility required to support your automated tests suites and enable you to find issues quickly and easily.
<format> in Visual Studio 2019 version 16.10
<format> in Visual Studio 2019 version 16.10
C++20 adds a new text formatting facility to the standard library, designed primarily to replace snprintf and friends with a fast and type safe interface. The standardized library is based on the existing {fmt} library, so users of that library will feel at home. Before diving into how std::format works I want to thank Victor Zverovich, ...
Preview of using CMake Presets for Azure Sphere development
Preview of using CMake Presets for Azure Sphere development
We are happy to announce that CMake Presets preview support is available in the Visual Studio 16.10 release as well as CMake Tools version 1.7 for Visual Studio Code. Erika introduced CMake Presets and why you should use them, this post will focus on how they can be used for Azure Sphere development across Visual Studio, VS Code, and GitHub...