This lot, the discussion about C++11 compliance and VS compliance has gave me quiet a startle... now I wonder what I can use or cant, if an piece of code fails due to none compliance or bad coding on my part.
Made me also wonder if VS is the compiler for me, I only use it because I am using the express ( free ) version and I figured it would be pretty much up to date compliance wise. Makes me wonder if I shouldnt look to using some other compiler, especially if I can lose the hassle of convincing users of my code to get the runtime dll for VS10.
... but I suppose at my current level ( beginner - intermediate sort of ) it wont really effect me , right ?
The new C++11 features make C++ easier to use as a beginner, so it's definitely something you should look into and learn piece by piece overtime, in the same way you learn the current version of C++ piece by piece over time.
Any old code won't become non-compliant - it's an extension of the previous standards, without discarding any previous parts.
Because the standard is so new (2011, hence the name), no compiler currently implements every part of the standard, though because working drafts of the standard have been available for years, the major compilers (Microsoft's and GCC/MinGW) already implement the majority of it, and certainly all the parts I mentioned in my post.
Some compilers require you to pass in a certain command-line parameter to 'unlock' the new features. GCC/MinGW requires '-std=c++11' to be passed in. (Presumably when they are 100% sure they've implemented the standard, it'd be turned on by default).
So your compiler may actually already be compliant, but you just accidentally have it turned off or it might be turned off by default. But it's perfectly stable and guaranteed not to change because it's been officially and permanently standardized.
Or, you just might be using an older version of your compiler, and just need to update to the most recent version.
There's no need to update this second, and no harm comes from waiting another year or so... I just wanted to get a a jump on C++11 myself, because the additions are so great, and because I'll need to learn them sooner or later anyway.
Uh, so to simplify:
- Definitely for beginners AND pros
- Old code still works fine, even if you update
- New features are awesome
- Visual Studio and GCC/MinGW have all the new features I mentioned, and more
- You'll want to learn them eventually, but it doesn't have to be now
- But you can use them now if you desire, just update your compiler