Hacker News new | past | comments | ask | show | jobs | submit login
C++11 will be introduced by B.Stroustrup at Microsoft Event (msdn.com)
72 points by alpb on Jan 21, 2012 | hide | past | favorite | 20 comments



I appreciate Microsoft's renewed commitment to native code but I'm rather disappointed at the limited C++11 support in the upcoming Visual Studio 2012 http://blogs.msdn.com/b/vcblog/archive/2011/09/12/10209291.a... especially when compared with gcc and clang.

gcc: http://gcc.gnu.org/projects/cxx0x.html

clang: http://clang.llvm.org/cxx_status.html

To pick a few examples, range-based for, variadic templates, and non-static data member initializers are huge improvements to the language.


Yep, those omissions are painful. I am not sure how the decision making process goes but if you look at the MS link vs the GCC one you will note that GCC has done basically nothing in the concurrency space in C++11, whereas MS will have implemented a number of items there. Clang is in the same boat there in terms of basically no work on the concurrency area.

As a member of the Visual Studio team (though I work on the IDE shell area, not the C++ compiler) I can say that the C++ team is a LOT smaller than many people seem to imagine. I think people imagine that VS is one giant team, it is really lots and lots of small-ish teams. The STL work is done by Dinkumware and I think there is one (maybe two) MS assets actually helping out there. One of the folks talking at Going Native (Stephan Lavavej) is said person, and he is awesome. The compiler work is split between a front-end and back-end team and obviously some pieces require coordinated effort from both teams to implement, on top of other non-standard requests they have to field. I personally would like them to focus 100% effort on purely standards only stuff until they get more 'caught up', but I don't run things :)

All of this takes nothing away from GCC and Clang, they are both awesome products developed over a long period of time by lots of accomplished compiler devs. MS has recently(-ish) spent more resources focusing on native development again after a long period of promoting basically all managed (or primarily managed), I think that is a good thing, balance is healthy.


> I'm rather disappointed at the limited C++11 support in the upcoming Visual Studio 2012

As a C user who's been waiting 12 years for MSVC to implement C99, I had to sardonically laugh when I read this. They don't even let you declare variables in the middle of a block!

Ironically the excuse they always give is that their customers want them to dedicate more of their time to C++11, not C: http://connect.microsoft.com/VisualStudio/feedback/details/3...


Honestly, that's probably right. I have no data, but I'd predict the number of C++11 programmers on Windows to dwarf C99 programmers.


I wasn't disputing that, I was just pointing out that OP was complaining about lack of C++11 support in Visual Studio compared to gcc and clang, but this is even more unfortunate considering the Visual Studio team has indicated that they prioritize C++11 support above other things.


Now if you're looking for a Linux IDE with C++11 support, KDevelop already does a lot more.


Visual Studio is still on a pretty long ship cycle (2-3 years), which makes it hard for them to pick up on new stuff like this. Perhaps they'll add more support in the SP1, if we're lucky.


They couldn't do full C++11 support because they were busy with this key feature: http://www.gamasutra.com/view/news/39717/Microsoft_gamifies_...


Isn't this a little weird, given that MSFT wants people to use "managed code", the CLI, and all the attendant software?

Or is it telling us that people who get to choose (free software) aren't going to be using C++11?

I can't tell.


Windows 8 WinRT is unmanaged/native; this has caused a conspiracy theory blaming infighting between Microsoft teams:

Why is WinRT unmanaged? http://stackoverflow.com/questions/7457371/why-is-winrt-unma...


Tangent: Ever notice how some of the most interesting threads on SO are [closed]? Especially the ones linked to from HN.

Edit: BTW, I didn't mean to imply that this was necessarily a bad thing. It's in keeping with the facts, not opinion, guidelines of SO, but an [opinion] tag might be a nice addition to SO. In this case, the question wasn't bad, and although some of the answers are mere speculation, comments like the one made by Larry Osterman help put to rest some of the BS that gets spread around in this industry.


In fairness, I think its because Hacker News is mostly about things that are matters of opinion, or at least worthy of four pages on the subject. Stack Overflow aims to be about one or two definitively correct, short and usable answers to specific, well-bounded, problems.


Which of those answers do you prefer? Accepted one seems a bit far fetched and simplistic. As Tatiana notes: "SharePoint is .NET, and it's half of Office.". Also see Larry's comment.


I'll warn in advance that this is the jazz hands answer, because it's really impossible to tell. I doubt any one person decreed WinRT should be native; most likely it was the best of many compromises. Anyone willing to name names while documenting the internal politics that went along with the decision(s) could write quite the page-turner!

* I could see decisions being influenced by long-term career prospects, but believe that people would be smart enough to hide most of this by working harder to find evidence supporting the direction they needed the tech to go.

* According to my limited understanding, Microsoft long ago threw out a bunch of OS-level managed development pre-Vista (WinFS-type stuff) in part because of performance related issues.

* ASP.NET (SharePoint) / managed code server-side is not going away any time soon, if ever... it's just too easy (and server hardware can typically handle any overhead).

* .NET client-side could go either way; I think this is what the accepted answer is saying (eg. Silverlight as this decade's VB6 - convenient LOB tool killed with no direct transition to new tech)

* Mono/Unity 3d/etc. are wildcards here, particularly as they support C# for non-Microsoft platforms (especially iPhone/Android).

* Microsoft, or at least powerful people within Microsoft, love COM (one of my least favorites, but I don't deal with cross-language runtime/binary compatibility).

I found this StackOverflow link on a huge discussion of the death of Silverlight, saying it was the first casualty of a "death to managed code" campaign: http://forums.silverlight.net/post/612643.aspx


The highest voted answer is clearly the sensible interpretation, but people do like to indulge in gossip and the 'politics' answer pushes those buttons.


I think Herb Sutter talked a fair bit about this at the Build and C++ and Beyond conferences last year.

The gist of it (IIRC) is that while managed code may be better for developer productivity, C++ continues to win when it comes to performance/size. Microsoft's trying to take a "best of both worlds" approach: promoting C++11 as a first-class language on Windows (WinRT), and making interop between managed and C++ code easier (C++/CX, formerly C++/CLI, formerly Managed C++).


What's wrong with the new standard? GNU g++ will be supporting it, right?


The compiler with probably the most existing support right now is gcc 4.7. I've been hearing that C++11 may become the standard mode as of 4.8.

http://gcc.gnu.org/gcc-4.7/cxx0x_status.html


>Isn't this a little weird, given that MSFT wants people to use "managed code"

What's really weird is MS sell a C++ compiler they don't want people to use!

>Or is it telling us that people who get to choose (free software) aren't going to be using C++11?

That'd be a real shame, for people to miss out on C++11 goodness just because they're MS-phobic.


> "C++11 feels like a new language" says C++ creator Bjarne Stroustrup

Great. Finally a reason enough to go back to C :-)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: