Jump to content
  • Advertisement
Sign in to follow this  

This topic is 2453 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

With both Clang and GCC having decent support for C++11, I'd like to start writing hobby projects in C++11. As far as I know, I don't believe there exists a published book on C++11, so I'm hoping to get from you all your favourites resources on the web where you've picked up C++11. I'm competent with C++03, so resources that assume prior C++03 experience are perfectly useful to me.

Thanks for your help!

Share this post


Link to post
Share on other sites
Advertisement
Have a look at these videos from the Going Native 2012 conference: http://channel9.msdn...oingNative-2012

Also Washu writes in his journal about C++11 which IMO provides a nice overview about some of the new concepts.
http://www.gamedev.n...from-the-washu/

C++11 has some quite nice language features in, but as these are *language*-features it feels sometimes like learning a new language. I also find that it may take some time to find out what the best practices for using the features are. For example auto is great many times, but sometimes it can make the code harder to understand because it hides the type-information from the developer.

Share this post


Link to post
Share on other sites

C++11? I can't say I have ever heard of it. My bad unsure.png

It's the new standard for the C++ language. It was known as C++0x for quite some time until the specs got ratified by ISO last year.

Share this post


Link to post
Share on other sites
What worked for the old (C++03) standard (probably) still works with the new standard. But a lot of things were "done right" and incorporated into the language itself instead of relying on template-libs like boost. It would be way too much to describe all the features here. The wikipedia-article that Cornstalks posted provides a good enough overview. Not all the stuff is already available in modern compilers, but quite a lot is already there. As I see it C++ took a giant step in evolving from "C-With-Classes" to it's own language.

Share this post


Link to post
Share on other sites
Scott Meyer's presentation is probably the best single source of information I've found. It covers a lot of the features which are not currently supported by most (any?) compilers. The downside is of course that it's a presentation, so you miss some of the information.

STL (the person), does a fantastic job explaining the new features. He's been covering them as they've been added to Visual Studio. Starting with TR1:

http://blogs.msdn.com/b/vcblog/archive/2008/02/22/tr1-slide-decks.aspx

A few minor changes to the library, but for the most part ignore the std::tr1 namespace, use std instead and those slides apply as is. That will cover many of the new features of the standard library, but not all of them. He also covered the C++11 features as they were added into VS2010 (static_assert, decltype, auto, lambdas, rvalue references, nullptr):

http://blogs.msdn.com/b/vcblog/archive/2008/10/28/lambdas-auto-and-static-assert-c-0x-features-in-vc10-part-1.aspx
http://blogs.msdn.com/b/vcblog/archive/2009/02/03/rvalue-references-c-0x-features-in-vc10-part-2.aspx
http://channel9.msdn.com/Shows/Going+Deep/Stephan-T-Lavavej-Everything-you-ever-wanted-to-know-about-nullptr

That information is a bit dated, but I do mean a "bit". Everything you see there should still work for you, but a few of the tiny details have changed like implicit move, etc. Herb Sutter's Lambas, Lambdas, Everywhere is also a good talk:

http://channel9.msdn.com/Events/PDC/PDC10/FT13

As mentioned before, the Going Native 2012 conference is great, especially the variadic templates talk. Stick to Day 1 though, Day 2 doesn't cover anything actually in C++11.

In general, the list of C++11 support in Visual Studio is a good source too, since it provides links to the proposals for each feature if you need some more information:

http://blogs.msdn.com/b/vcblog/archive/2011/09/12/10209291.aspx

And if you're lucky enough to come across a copy of n3290 or n3291, grab it. It's the official standard which is still selling for hundreds of dollars. Otherwise grab the latest draft and go off that.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!