C++ Team Blog

The latest in C++, Visual Studio, VS Code, and vcpkg from the MSFT C++ team

How we used C++20 to eliminate an entire class of runtime bugs

C++20 is here and has been supported in MSVC since 16.11, but today's post is not about how you can use it, but rather how we used it to effectively eliminate an entire class of runtime bugs by hoisting a check into compile-time. Let's get right into it! Humble beginnings In compiler design one of the very first things you need is a way to ...