Visual C++ Team Blog
blogs.msdn.microsoft.com/vcblog · Company blog · on HN since 2016
Microsoft's Visual C++ team announces compiler, standard library, and tooling updates for C and C++ developers.
What HN saysCommenters cite it for MSVC standards progress, such as C++17 STL completeness, and for details on the C runtime and macro tooltips.
86HN people shared it
52linked it in comments
91stories submitted
1.2Kstory points
8 years agolast shared
2016people per year2026
Most-shared posts
- 1Spectre mitigations in MSVC5 people · 21 points · first shared 2018 · 1 comments on HN
- 2C/C++ Extension for Visual Studio Code4 people · 60 points · first shared 2016 · 20 comments on HN
- 3Two-phase name lookup support comes to MSVC4 people · 5 points · first shared 2017 · discussion on HN
- 4CMake support in Visual Studio4 people · 5 points · first shared 2016 · discussion on HN
- 5Announcing the vs gdb debugger extension4 people · first shared 2016
- 6Clang with microsoft codegen in vs 2015 update 14 people · first shared 2016
- 7Vs 2015 update 2s stl is c17 so far feature complete4 people · first shared 2016
- 8Visual C++ for Linux Development3 people · 271 points · first shared 2016 · 93 comments on HN
- 9Announcing: MSVC Conforms to the C++ Standard3 people · 42 points · first shared 2018 · 2 comments on HN
- 10Announcing: MSVC Conforms to the C++ Standard3 people · 14 points · first shared 2018 · discussion on HN
- 11Security Features in Microsoft Visual C++3 people · 7 points · first shared 2017 · discussion on HN
- 12MSVC code optimizer improvements in Visual Studio 2017 versions 15.5 and 15.33 people · 5 points · first shared 2017 · discussion on HN
- 13May update for the C/C++ extension in Visual Studio Code3 people · 5 points · first shared 2016 · discussion on HN
- 14Visual Studio 2015 C++ Build Tools – now with ATL/MFC libraries3 people · 4 points · first shared 2016 · discussion on HN
- 15Compiler improvements in VS 2015 Update 23 people · 3 points · first shared 2016 · discussion on HN
What HN people wrote when they linked it
pjmlp · 2018-11-19
You don't, the best you can hope for is tooltips.
https://blogs.msdn.microsoft.com/vcblog/2018/05/07/macro-expansions-in…
Or you convert them to C++ constexpr templates, which you can easily step on the debugger.
userbinator · 2017-09-08
MS does supply the MSVCRT.DLL with Windows, and even link their apps with it, but then said you (as in, non-MS apps) weren't supposed to use it in lieu of the MSVCRxxx (and now, the even worse "split the libc into several dozen pieces, each in its own file"[1]) mess.
Most developers grudgingly obeyed, bloating their apps either through static linking, including a copy of the set of runtime DLLs, or the .MSI installer in their own distribution.
But then there are those of us who saw through that ruse, gave MS the proverbial finger and linked with the "system MSVCRT.DLL". The result being tiny, highly portable binaries which don't require any installation or dependencies beyond what Windows already has.
[1] https://blogs.msdn.microsoft.com/vcblog/2014/06/10/the-great-c-runtime…
Salgat · 2017-01-13
The folks working on the Microsoft compiler have done a fantastic job lately keeping up with features, so I wouldn't call them years behind.
https://blogs.msdn.microsoft.com/vcblog/2016/01/22/vs-2015-update-2s-s…
anonymfus · 2016-10-06
>Starting with Visual Studio “14,” we will stop releasing new versions of the CRT with each release of Visual Studio. Whereas before we would have released msvcr140.dll in this forthcoming release, then msvcr150.dll in the next release, we will instead release one new CRT in Visual Studio “14” then update that version in-place in subsequent releases, maintaining backwards compatibility for existing programs.
From this post: https://blogs.msdn.microsoft.com/vcblog/2014/06/10/the-great-c-runtime…
panic · 2016-09-08
It's worth noting that Microsoft Visual Studio doesn't have very good C support: it still doesn't support all of C99. You can either use clang as a frontend on Windows (https://blogs.msdn.microsoft.com/vcblog/2015/12/04/clang-with-microsof… or use C++: almost all of C++11 is supported (https://msdn.microsoft.com/en-us/library/hh567368.aspx).
nofunsir · 2018-07-19
TL;DR: Just set up the "Build" toolchain (configuration) in Qt Creator and point Qt Creator at your target (with the correct ssh user login) for when you click "Run" or "Debug".
http://wiki.qt.io/Raspberry_Pi_Beginners_Guide
http://wiki.qt.io/RaspberryPi2EGLFS
These two tutorials use slightly different setups, so don't get confused on details, but both are great to glean tips from.
I've successfully used Qt Creator on both a Linux VM (desktop Intel) and a Windows desktop to build originally-desktop-based Qt projects for embedded Linux on ARM. The projects are not headless, but also do not use X to run the Qt GUI. Instead they use EGLFS.
Even if your software doesn't have a GUI, you can still do remote debugging with Qt Creator... or Eclipse, or Visual Studio , or anything that has the proper hooks.
I don't think any sane developer would want to use a remote X server to get to an instance of an IDE.
As long as you have the proper cross toolchain (some cost $) set up correctly in Qt, and your target code is all included properly (libraries and headers for your target, NOT your dev machine), you should be able to do exactly what you want for any desktop+remote target pair.
Additionally you don't even have to work in Linux to target Embedded Linux:
https://wiki.qt.io/Visual_Studio_Add-in
https://blogs.msdn.microsoft.com/vcblog/2016/03/30/visual-c-for-linux-…
jcelerier · 2017-09-03
> So number of opponents is very minor but they make lots of noise. While the 'normal' people, those who really enjoy dictate are great majority, alas, not very vocal. This is communist lingo bro.
No, this has some basis: http://assets.csom.umn.edu/assets/71516.pdf
You never hear anyone going to post "oh wow I love systemd/my dell laptop/this website/" unless specifically asked, or when answering seemingly biased or sometimes incorrect "bad" reviews. I personally enjoy managing my computers much more since systemd.
That's like other technology stacks. For instance, some people were burned by CMake in 2008, didn't try to understand its logic and you still see them complaining on forums up to this day and you may think that this is a shitty unused buildsystem; but when Microsoft and Jetbrains did actual surveys it came out as very strong (more used than make) and growing:
https://blogs.msdn.microsoft.com/vcblog/2016/10/05/cmake-support-in-vi…
https://www.jetbrains.com/research/devecosystem-2017/cpp/
StephanTLavavej · 2016-11-16
MSVC STL dev here. We're doing something different this time around. VS 2015 RTM and Update 1/2/3 were binary-compatible (as usual) while adding lots of features to the compiler and STL (unusual). VS 2017 RTM and its Updates will continue to be binary-compatible while adding features, meaning that our DLLs are still vcruntime140.dll, msvcp140.dll, etc. The versions are admittedly a mess, so here's the magic decoder ring:
VS 2015: IDE version 14, DLL version 140, toolset version 140, compiler version 19.0 (the C++ compiler is older than the Visual part of Visual C++).
VS 2017: IDE version 15, DLL version 140 (same!), toolset version 141, compiler version 19.1
We still recommend that you build everything with VS 2017 consistently, as this will give you the most performance and correctness. However, you can mix in object files, static libraries, and DLLs compiled with previous versions all the way back to 2015 RTM, and things will continue to work (although you won't necessarily activate fixes in the newer version).
For more info, read the comments on https://blogs.msdn.microsoft.com/vcblog/2016/08/24/c1417-features-and-… where I mentioned WCFB02.
apardoe-MSFT · 2016-06-09
VS/MSVC has improved a lot. There are details here: https://blogs.msdn.microsoft.com/vcblog/2016/06/07/compiler-improvemen… but the long and short of it is that we are working on achieving complete C++98/11/14 compliance by (hopefully) the end of this year. And we have a number of C++ draft standard features implemented already, in both the compiler and the libraries.
Additionally, we're shipping a number of versions of Clang in VS (targeting Windows, targeting Linux/IOT, targeting Android/iOS) and contributing to the community. We're looking seriously into CMake support and contributing back to the community. And the VS Code editor runs on Unix-based OS with IntelliSense, debugging, etc.
So yes, VS has improved a lot, but we still have work to do.
I'd love to chat with you if you have questions. My email is [email protected]. My full name is on the blog that I linked to but I'm really not that hard to find online.
And I've got questions for you if you use Clang and have any interest in Windows. Send me mail and we can maybe set up time for a phone/Skype call.
SiVal · 2016-04-01
And now with the one you excluded (VS Code), we are seeing them making a serious move on your two big advantages of IDEA over VS.
They have apparently built a lot of the "big" VS in C#, and they have apparently architected VS Code with a C# runtime on top of Electron to make it easier to port big pieces of VS into VS Code.
Today they announced a preview of their upcoming C/C++ extension (https://blogs.msdn.microsoft.com/vcblog/2016/03/31/cc-extension-for-vi… and they say their Python tools for VS are coming to VS Code this year.
And VS Code "runs on my platform(s)".
The more developers they convert to VS Code, which is a lot deeper than just an editor for C# and Typescript, the more influence they will have on development patterns on all platforms. This seems like a bigger push than just "make Windows the best platform for developing for all platforms". They're attempting to get devs who continue working on Mac and Linux to switch to their dev tools.
int_19h · 2019-01-05
By "libc" I mean the userspace layer here broadly - on Windows that would be kernel32 etc. What VC++ calls CRT is built on that in turn.
Although as of Win10, the actual CRT is also an API-stable OS-level component now, not a VC++-specific thing: https://blogs.msdn.microsoft.com/vcblog/2015/03/03/introducing-the-uni…
The right thing here is the general notion of abstracting away core kernel APIs in userspace. It lets you refactor the whole thing significantly without breaking everything. And userspace calls are easier to maintain long-term for legacy support reasons, as well (at some point you can make it into a DLL that doesn't even have to be distributed with the OS, and just ship that with apps that need it).
Tempest1981 · 2018-07-01
With VS2017, they've moved to a faster release cadence. Fortunely, the minor releases are actually delivering significant features, like C++17 conformance.
The downside is occasional toolset compatibility issues. https://blogs.msdn.microsoft.com/vcblog/2017/11/15/side-by-side-minor-…
gurkendoktor · 2018-06-19
It was probably the placeholder icon for MFC apps, shown in the middle at the end of this blog post:
https://blogs.msdn.microsoft.com/vcblog/2017/02/27/happy-25th-birthday…
JdeBP · 2018-06-01
Bat-Ulzii Luvsanbat claims to know about MSVC.
* https://blogs.msdn.microsoft.com/vcblog/2018/05/07/announcing-msvc-con…
cesarb · 2018-05-20
TwoBit · 2018-05-20
I just found this statement from Microsoft:
https://blogs.msdn.microsoft.com/vcblog/2017/09/11/two-phase-name-look…
"MSVC previously recorded the body of the template as a stream of tokens and stored that stream away to be replayed at instantiation time. The behavior of MSVC’s template substitution from a recorded token stream somewhat resembled the behavior of macro substitution in that limited analysis was done of a template’s body."
jchb · 2018-05-10
Yes, but the final version of the C++17 standard was released as late as December 2017, so support may not be "production ready", neither in gcc nor in other compilers.
You can the summary of the gcc c++ standard support here: https://gcc.gnu.org/projects/cxx-status.html#cxx17.
Full support for all features in the c++17 standard, but the support is declared "experimental".
Similarly here for clang:
https://clang.llvm.org/cxx_status.html
And Visual studio:
https://blogs.msdn.microsoft.com/vcblog/2018/04/26/announcing-msvc-con…
(link to latest blog post, perhaps there is a status page that gets updated, but could not find it).
wahern · 2018-03-06
Microsoft backpedaled not longer afterwards. See, e.g.,
https://blogs.msdn.microsoft.com/vcblog/2013/06/28/c1114-stl-features-…
and
https://blogs.msdn.microsoft.com/vcblog/2013/07/19/c99-library-support…
They even added C99 compound literals and designated initializers:
https://msdn.microsoft.com/en-us/library/hh409293(v=vs.120).aspx
Compound literals could never be added to C++ because the syntax and semantics conflict with existing C++ constructs.
taspeotis · 2018-01-24
I'm not sure how close this is to the retpoline mitigation but ... https://blogs.msdn.microsoft.com/vcblog/2018/01/15/spectre-mitigations…
Our tests show the performance impact of /Qspectre to be negligible. We have built all of Windows with /Qspectre enabled and did not notice any performance regressions of concern. Performance gains from speculative execution are lost where the mitigation is applied but the mitigation was needed in a relatively small number of instances across the large codebases that we recompiled.
zvrba · 2017-11-16
> but it's under threat of depreciation because the bootsrap build with MPX has been broken for so long.
Huh. Even MSVC supports it (currently experimental though): https://blogs.msdn.microsoft.com/vcblog/2016/01/20/visual-studio-2015-…
stinos · 2017-08-26
Windows is a pain to program on,
It's really not, if you know how to do it. But that goes for any OS out there. I mean, put a seasoned visual-studio-on-windows-only dev in front of a linux box and tell him to set up the build of a non-trivial application and watch what happens. Chances are pretty high the answer is 'linux is a pain to program on' :]
but I still want to use "normal" clang, so I have to generate a unix makefile
https://blogs.msdn.microsoft.com/vcblog/2017/03/07/use-any-c-compiler-… it's still relatively young but seems to work quite ok
corysama · 2017-03-28
The C++ Core Guidelines Checker, in combination with the Guidelines Support Library, is supposed to bring Rust-like memory safety guarantees to C++. Has anyone here had a chance to try it out?
https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuideli…
https://github.com/Microsoft/GSL
https://msdn.microsoft.com/en-us/library/mt762841.aspx
https://blogs.msdn.microsoft.com/vcblog/2016/10/12/cppcorecheck/
Microsoft has been embracing the idea. But, the GSL and Checker are both compiler-independent.
shakna · 2017-03-25
GCC [0] is pretty much done.
Clang [1] needs a couple more things.
MSVC [2] hasn't done as much, but shouldn't be too far away. [3].
Considering how long C++11 took before it was fully implemented, this seems so fast!
[0] https://gcc.gnu.org/projects/cxx-status.html#cxx1z
[1] http://clang.llvm.org/cxx_status.html
[2] https://msdn.microsoft.com/en-us/library/hh567368.aspx
[3] https://blogs.msdn.microsoft.com/vcblog/2016/01/22/vs-2015-update-2s-s…
bitcrazed · 2017-02-22
Did you watch the video? ;) Take a look at Visual C++ for Linux: https://blogs.msdn.microsoft.com/vcblog/2016/03/30/visual-c-for-linux-…
1wd · 2017-02-21
> Bash on Windows or Bash/WSL got the most votes in early polling while we were choosing a descriptive name for this unusual feature, especially compared to WSRPGLB (Windows Subsystem for Running POSIX, GNU, Linux Binaries) which felt a little cumbersome
https://blogs.msdn.microsoft.com/vcblog/2017/02/08/targeting-windows-s…
vmarsy · 2017-02-21
those are some cool changes. For those who can't/don'w want to watch the video:
- 24 bit color support added.
- lots of work to support more programs
- launch windows programs from bash (notepad.exe for instance)
- file change notification support (to allow for automatically rebuilding a website on file change for instance)
- can build a C++ project in Visual Studio and deploy it to your local WSL env, so you can run it directly from the local bash. (Visual Studio generates real linux binaries : ELF 64 bit lsb executable)
- Remote GDB Debugger: Can use visual studio debug engine to debug linux executables (It looks like this was possible before for remote machines [1], but now it can be done locally on a program running in WSL.)
[1] https://blogs.msdn.microsoft.com/vcblog/2015/11/18/announcing-the-vs-g…
pzone · 2017-02-07
No, they keep up pretty well with the C++ spec.
https://blogs.msdn.microsoft.com/vcblog/2016/01/22/vs-2015-update-2s-s…
You may be thinking of the lack of full C99 support.
Koshkin · 2017-02-07
Incidentally, it looks like Visual Studio 2017 will support CMake: https://blogs.msdn.microsoft.com/vcblog/2016/10/05/cmake-support-in-vi…
krona · 2017-01-29
Visual Studio 2017 has built-in support for C++ Core Guidelines static analysis suite.
more info: https://blogs.msdn.microsoft.com/vcblog/2016/10/12/cppcorecheck/
BudVVeezer · 2017-01-23
Is it the /d1reportSingleClassLayoutXXX flag, described here?
https://blogs.msdn.microsoft.com/vcblog/2007/05/17/diagnosing-hidden-o…