C++ Team Blog
The latest in C++, Visual Studio, VS Code, and vcpkg from the MSFT C++ team
Latest posts
Visual Studio Express 2012 for Windows Desktop
As you may have seen, Soma announced today that Visual Studio Express 2012 for Windows Desktop is now available for download. For C++ developers, the Express for Windows Desktop includes many of the new C++ investments we made in Visual Studio 2012, including C++ AMP, improvements to C++ 11 Standards conformance, improvements to the compiler and linker, and the IDE. It also includes the 64-bit cross-compiler and 64-bit C++ libraries, the C++ unit testing introduced in Visual Studio 2012, and a targeted set of code analysis rules to help you build more reliable applications. And while we’re...
C++/CX Part 1 of [n]: A Simple Class
See C++/CX Part 0 of [N]: An Introduction for an introduction to this series. In this article we'll consider the basics of C++/CX by looking at a simple Windows Runtime class; we'll skim over some of the details, but don't worry: we'll come back and cover them in future posts. The code in this post is complete, though some namespace qualification is omitted for brevity; attached to this article is a Visual Studio solution containing the complete code for both the C++/CX and the WRL component, along with a simple test app that uses both. Alright. Here's our simple class: This is a rather silly class, but ...
C++ AMP Resources
Hopefully by now you have heard of C++ AMP. C++ AMP is a modern C++ library (plus a key new language feature) that ships with Visual Studio 2012 and it lets you take advantage of accelerators, such as the GPU, for compute purposes. Think data parallelism, but at a massive level, accelerated by powerful hardware. If you need more motivation on how using C++ AMP can speed up code, check out the nbody or the morph demo.To follow the C++ AMP story, you should subscribe to the Parallel Programming in Native Code blog. Over the last year we have published (and updated for RTM) a number of Visual Studio s...
C++/CX Part 0 of [n]: An Introduction
Hello; I'm James McNellis, and I've recently joined the Visual C++ team as a libraries developer. My first encounter with the C++/CX language extensions was early last year, while implementing some code generation features for the Visual Studio 2012 XAML designer. I started off by hunting for some example code, and it suffices to say that I was a bit surprised with what I first saw. My initial reaction was along the lines of: "What the heck are these hats doing in this C++ code?" Actually, I was quite worried; because I thought it was C++/CLI—managed code. Not that managed code is bad, per se, but I'm ...
Connecting C++ and XAML
Hi, I’m Andy Rich, a tester on the C++ frontend compiler and one of the primary testers of the C++/CX language extensions. If you’re like me, making use of a technology without understanding how it works can be confusing and frustrating. This blog post will help explain how XAML and C++ work together in the build system to make a Windows Store application that still respects the C++ language build model and syntax. (Note: this blog post is targeted towards Windows Store app developers.) The Build Process From a user-facing standpoint, Pages and other custom controls are really a trio...
Visual C++ in Visual Studio 2012
If you have read Jason Zander’s post earlier today, you know that Visual Studio 2012 has been released to the web! Check out the MSDN Subscriber Download Page and the Visual Studio product website. This release has brought a huge amount of new value for C++ developers. Here are the highlights: C++11 Standards Support Language Support Standard Template Library Here is the detailed discussion on C++ 11 features in Visual Studio 2012, with links to the corresponding C++ 11 specs. Please also see the fun video series on STL … by STL. Paralle...
Compiler Bugs Fixed In Visual Studio 2012
Template Argument Deduction – Core C++, Part 2
Part 2 of my third video lecture series (covering the C++ Core Language) is now available. In this part, I took an hour to explore template argument deduction, including what "non-deduced contexts" are - and how they can be used to your advantage! For reference, here are all of the links to my video lectures, plus my GoingNative 2012 presentation: [STL Introduction]Part 1 (sequence containers)Part 2 (associative containers)Part 3 (smart pointers)Part 4 (Nurikabe solver) - see Wikipedia's article and my updated source codePart 5 (Nurikabe solver, continued)Part 6 (algorithms and functors)Part 7 (a...
Debugger Type Visualizers for C++ in Visual Studio 2012
In Visual Studio 2012, one of the new features for C++ developers is the new native type visualization framework (natvis) added to the debugger which allows customizing the way data types are displayed in debugger variable windows (e. g. autos, watch, locals, and data tips). For those who are familiar with the autoexp.dat file that has been used in earlier versions of Visual Studio, this new visualization framework supersedes that and offers xml syntax, better diagnostics, versioning and multiple file support. To illustrate how type visualizers help make it easier to inspect objects, the following scree...