Where do you track the developments of new c++ standards? - c++

Where do you guys generally look for developments in C++, most importantly, developments in new standard and its approx/scheduled release data? also boost (well, boost.com)
Is there a centralized place?
thx

You go to the C++ Standard Committee website:
Home: http://www.open-std.org/JTC1/SC22/WG21/
And for a quick access to any published papers:
http://www.open-std.org/jtc1/sc22/wg21/docs/papers/

In the past I've used the C++0x wiki entry, and to a lesser extent, the Informit C++ Reference. Recently, I came across a new blog that people may want to check out. It appears to have been started by a couple of committee members:
We started this site because the community at large seems especially hungry—right now—to know more about, and to be more involved in, what's happening on the cutting edge of C++. We're going to be writing articles on C++0x and advanced C++03.
...
Thanks for visiting C++Next,
Dave Abrahams and Doug Gregor
http://cpp-next.com

A lot of insiders to the standards working group discuss and post at comp.std.c++ so I guess that would qualify.
Another good place is Herb Sutter homepage and blog.

Trawling through my own answers, I just found this old question and realised that, while all other answers (including my own) are still valid, there is now one more important site that has been added to the list:
http://isocpp.org/
This is run by the committee themselves and has regular updates on the status of C++. And, recursively, also points to the occasional StackOverflow post.
They also usually tweet from #isocpp, when an article is posted or updated, or about other C++ issues, such as videos from recent C++ conferences.

Since I lurk on the Boost Developers' mailing list, I tend to become informed of interesting new developments in the Standard that way. There is usually an announcement of some kind by the folks who are both in Boost and on the committee, and this usually prompts me to look at the committee papers, and also provides for some very interesting informed discussion.

C++ has been updated much here lately. I would recommend wikipedia's article on C++ though. It usually is kept up to date (not that a lot's changed). I guess the closest thing to a specification that I've found is Bjarne Stroustrup's book (the creator of the C++ language) on, what else, the C++ language.

I think the best places to start would be e.g.:
C++17 - Wikipedia
c++ - What are the new features in C++17? - Stack Overflow
C++20 - Wikipedia
C++20 - cppreference.com
etc.

Related

When is the planned date for C++0x to be released into the wild?

We've been waiting forever to see if it's going to become a full-fledged language, and yet there doesn't seem to be a release of the formal definition. Just committees and discussions and revising.
Does anyone know of a planned deadline for C++0x, or are we going to have to start calling it C++1x?
Well the committee is currently very busy working on the next revision - every meeting is prefaced by many papers, that are a good indicator of the effort that is going into the new standard: http://www.open-std.org/jtc1/sc22/wg21/
What is a little concerning (but reassuring in the sense that they will not rush publishing a standard just to assuage the public, yet do sense the urgency involved) is that Stroustrup just put out a paper saying that we need to take a second look at concepts and make sure that they are as simple as can be - and has proposed a reasonable solution.
[Edit] For those who are interested, this paper is available at: http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2009/n2906.pdf.
C++0x will be a huge improvement upon C++ in many regards, and while I do not speak for the committee - my hope is that it will happen by late 2010.
[Edit] As underscored by one of the commenters, it is worth appreciating that there is significant concern amongst a few committee members that either the quality of the standard or the schedule (late 2010) will have to suffer if concepts are included: http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2009/n2893.pdf. But whether these concerns will be substantiated is worth being patient about - we will have more information about this once the committee concludes its meeting in Frankfurt this july (the post-meeting mailing can be expected in late-july, early august).
Personally, i sense that it would not be a huge loss to get the standard out without concepts (maintain the late 2010 schedule), and then add them as a TR - versus rushing them through even when there is palpable uneasiness amongst the more seasoned committee members (about concepts) - but I will defer to the committee here - while they have never claimed or been described as perfect, the majority of them are far more qualified to make these decisions than I am and deserve some of our confidence if history is any indicator - I would err on the side of trusting their instincts (over mine) assuming there was some reasonable consensus amongst them.
For some perspective, and so that one does not despair about these obstacles too much, compare this to what happened within the ecmascript community - Brendan Eich, the creator, had some very different design goals for the next revision of ecmascript (es5) from some of the other similarly talented wizards in the ecmascript community - they had multiple meetings and after much discussion (some of it heated ;) formulated a very very reasonable compromise followed by a frenzy of activity that has resulted in ecmascript 5 (all in the span of 1-2 years, including the conflict) which will be an excellent and pragmatic, yet much more conservative than Eich had initially proposed, revision of javascript. I have similar hopes for C++ (acknowledging that C++ is a much much much larger language - but then much more effort has been put in ;)
FTR: C++11 has been approved by ISO on 12 August 2011.
Around 200A or 200B. If you remember the Y2K problem, these are years 199K and 199L ... oops wait, K and L aren't hex digits. Boom!
Slashdot posted a story of an interview with Bjarne Stroustrup, and in it, he drops the bombsheel that the release has been delayed until 2010 or later:
No C++0x, Long Live C++1x (Page 3)!

Should every C++ programmer read the ISO standard to become professional?

Should every C++ programmer read the ISO standard to become professional?
No. C++ standard is more like a dictionary - something where you look up specific things that concern you at any given moment. It doesn't make a good (or useful) reading if you treat it as a simple book to read from beginning to end.
If the question were whether every professional C++ programmer should have an ISO standard at hand, and use it for reference as needed, then I'd say "yes".
I think that every professional C++ programmer should have a copy of the standard to refer to. But a sit down and slog through it, cover-to-cover read would be pretty numbing. It's mostly written for implementers (compiler writers), and it has next to no explanation of rationale for why the standard requires certain things.
So, I'd say it's more important for a professional C++ programmer to have and read:
Stroustrup's "The C++ Programming Language"
Meyer's "Effective..." series and/or Sutter's "Exceptional..." series
Lippman's "Inside the C++ Object Model"
Stroustrup's "Design and Evolution of C++"
Or at least some decent subset of them. If you have a chunk of those books under your belt, you'll only be going to the Standard for minutiae or to settle arguments.
By the way, see this answer for pointers on how to get the standard documents:
Where do I find the current C or C++ standard documents?
I think a lot of things like, "is this ok to do?" are only really answered by looking at the standard.
You can learn a lot of things by reading the standard, because it includes all the tiny details people tend to skip out on.
Having standard on hand also helps you back up your statements, because if someone says, "This is okay to do", you can say, "Actually, according to the standard, it's not okay because..."
I think in conclusion, I'll repeat what I've said before:
Knowing it can't hurt you, but you don't need to have it memorized to be a good C++ programmer.
If they're getting paid to write C++, then they are already a professional :)
But I don't think it should be required of any language to get respect. I'm sure there are plenty other uses of such time that might benefit your skillset more.
Should every driver memorize the DVM laws to become professional? It might help, but it would also a ton of work that they probably don't have the time for. Maybe reading a book like Code Complete might be more beneficial.
I'd answer with a few questions:
how much value does it provide to the developer to read the ISO standard?
Are employers demanding this attribute of their developers?
How will it make a developer's code more maintainable, and readable?
Will the reading of the ISO standard help the developer make the developers around him/her any better?
(This sounds like a wiki question.)
No. That's not how people learn effectively, and most people won't retain information after reading a spec. You need practice for information to sink in, and there's no way to get that without implementing things. Also, a lot of programmers only need to use a subset of C++, and can page-fault new information in as-needed.
Rather than reading specs, Your time is better spent learning generally how to program, how to write documentation, how to implement algorithms, and learn the more detailed facets of the C++ as you go.
Understanding how and when to read the standard are more important than just reading to to cure insomnia. Of course this applies to all the standards out there that are related to whatever you are doing. There is defiantly a skill to reading and understanding a standard. And knowing when to read them rather than just throw questions to Stackoverflow or any other random web site is a skill that is missing in many programmers (new and old). But I agree with Michael Burr and asperous.us... there are other books that should be read first.

Is it Wise to Spend Cash on a C++ Book Keeping in View the Upcoming C++0x?

I just purchased C++ GUI Programming with Qt4 and after reading the code samples in this book I'm beginning to realize that my knowledge of C++ is incomplete. I learned C++ two years ago from online tutorials and a couple of ebooks I downloaded, and it turns out none of these resources were good enough. Since then I haven't touched the language and have been using Python instead.
Now I'm thinking of purchasing a good book on C++ that covers advanced topics, and the one I have in mind is Bruce Eckel's Thinking in C++ (both volumes). I know they are available for free on the web, but I really can't stand reading books on a laptop screen.
Since C++0x might be out pretty soon, is it wise to go ahead and spend cash on these books? Will C++0x break backwards compatibility? Volume 2 covers features like multithreading, templates etc. Would any of these features change significantly in C++0x?
I wouldn't hold my breath for C++0x. I doubt it will be out by the end of this decade. Even when it will be out, you should probably count a year or so for compilers to implement it. Learn the fundamentals now, and it should be relatively easy for you to learn most of the new features when the standard is out. The Standards Committee is known for its efforts to maintain backward compatibility.
I personally check with the evolution of the standard from time to time, just out of curiosity. Subscribe to Herb Sutter's blog feed and look for Standard updates.
My personal favourite advanced C++ book is Bjarne Stroustrup's The C++ Programming Language, 3e. It is the one single C++ book from which I think I learnt the most, with respect to language and STL details. Scott Meyers' books helped clarify a lot of things too. Meyers writes in a very readable language (English, I believe), and often what would happen is that I'd read an entire Item from Meyers' book, and then find the same information in Stroustrup's book condensed into a single sentence or so. That is to say Meyers' books are extremely useful in getting your attention to interesting details.
As for the changes I expect for threading, I think there going to be two new libraries for this purpose in the standard. Concepts are an even bigger change coming, and they are somewhat related to templates. Up until now we had concepts in the STL, but these were conventions; an algorithm would make assumptions about a type you pass to a template, and you'd know to pass the correct "type of type" because of the conventions. This implied terribly error messages, the STL template errors we all know and "love". Concepts will help solve these. There are other improvements (complexities) to the language. Herb Sutter talks about them a lot.
It is certainly wise to buy the book. C++1x will hardly break with previous code. Nearly everything you learn is also possible with the next C++, and it will greatly help you understand the need of why C++1x will introduce what feature. For example, why will it have variadic templates, and why those concepts?
Even if the backward compatibility is broken on some features, the biggest part should be still usefull.
Furthermore, the first books on C++Ox might not be the best ones.
I would prefer a very good book on C++ to a book on C++Ox.
I would definitely go for buying the books
Those from Eckel are really good books, and I really recommend them.
It will take several years for compilers to catch up with new features introduced with C++0x (just look how was with template support!)
It will take even more years for projects to start using them
Finally, although I do not know with detail the3 changes introduced with the new release of the language, the C++ committee has always been very conservative on backward compatibility, therefore you should do not have any risk of learning something will be obsolete soon.
I'd echo the recommendation to get the Bjarne Stroustrup book "The C++ Programming Language
(Third Edition and Special Edition)" http://www.research.att.com/~bs/3rd.html in addition to any other book you may be interested in, if you can afford multiple books. If you can afford only one and have mastered the basics (as you have) then I'd probably learn towards the Stroustrup book. You can't go past getting the facts from the man himself.
You can track developments in C++0x here:
http://www.research.att.com/~bs/C++0xFAQ.html
if you are interested. As previously commented, I wouldn't hold my breath if I were you.
You might try a site like Safari Books Online to keep up-to-date with technical and programming books. I've bought several Ruby- and Ruby on Rails-related books in the past and they're now much less useful because the stuff in them is deprecated.

Developing as a programmer

I have been learning C++ for three months now and in that time created a number of applications for my company. I consider myself fairly comfortable with C++ / MFC and STL, however I don't just want to be an OK programmer, I want to be a good programmer. I have a few books on best practices but I was wondering if anyone could suggest reading materials that helped them and any disciplines which should be encouraged?
Thanks!
I would start with the Pragmatic Programmer, Code Complete, Refactoring and Design Patterns.
For C++, Scott Meyers books are very good, and will help take you to the next level.
If you don't already have it C++ by Bjarne Stroustrup, 3rd Edition
Uhm... Teach Yourself Programming in Ten Years (Peter Norvig)
3 months into c++ and you're already comfortable with it? Sheesh, I've been learning c# for over a year and have taken numerous Microsoft courses and I'm nowhere near comfortable with it.
That being said, you'll hear Code Complete tossed about as a very good book. I'm in the process of reading it now.
Marshall Cline's C++ FAQ Lite.
Herb Sutter's Exceptional C++.
Large Scale C++ Software Design by John Lakos gives guidance on design methods that will make your C++ more maintainable. It is pretty hefty but you can dip in and still get some benefits.
Somewhat off-topic: rather than suggesting books to learn, I'd like to mention some broad topics to consider.
Threading. This one is not much in demand if you use MFC, but in many other areas it's indispensable. The mechanics of threading APIs are easy to pick up, but learning all the corner cases takes a lot of time and practice.
Closures, Map-Reduce and other lisp-like techniques. Find out what they are, why they are not supported in C++, and how they are imitated in C++ (functors, and many other cases of stateful callback objects). For this I actually have a book: "Structure and Interpretation of Computer Programs".
Command Line. This gives you an idea on when not to code your own programs. Command line would be Unix command line - I don't know about MS's latest experimentation in this are, but cmd.exe is awful. Get Cygwin and start experimenting.
Scripting languages. This gives you an idea on when not program in C++. My favorite is Perl, but many people say Python, Ruby and whatnot. Hey, learn XSLT if you're so inclined!
I am sure I left out other areas. I'll mark this as Community Wiki - feel free to add.
Good blogs:
Guru of the Week, and all the books by Herb Sutter. Those will give you quite a lot to chew already.
Modern C++ Design by Alexandrescu if you want to get a good feel for what you don't yet know, and probably don't want to know.
Code Kata's for practice!
I have read several (not complete but some parts) of oreilly books on VB.net they are quite good, but if you want to be pro and have the time...
You can try out MSDN forums, help other people and discuss with them hard and complex problems, I think it's the best way..
learn another language. even if you won't use it, it's great for mind-opening.
I'd advice Lua, Scheme and Python. but almost anything else would do. (the most different from C, the best)
Josuttis and Vandevoorde - Templates: The Complete Guide
As I see, nobody mentioned Bruce Eckel brilliant books "Thinking in C++". IMHO, it`s one of the best books to start your C++ development from. From my point of view, first volume is more helpful that the second, but both of them worth reading.
http://www.amazon.com/Thinking-C-Introduction-Standard-One/dp/0139798099/ref=pd_bbs_sr_1?ie=UTF8&s=books&qid=1227890306&sr=8-1
I lot of folks can suggest more modern, up-to-date books. But I still recommend The Annotated C++ Reference Manual by Margaret A. Ellis & Bjarne Stroustrup.
The ARM was published back in '90. It's become somewhat outdated with respect to templates. STL is (obviously) absent. (Though the website at sgi.com does a good job of covering STL!)
However, the ARM is dirt cheap (used). (Shipping will exceed the cost of the book.) Its signal-to-noise ratio remains off the scale. It's very good at digging into C++'s dirty areas, explaining what was done & why.
I still use it as a reference. I rank it up there with K&R.
Dietel/Dietel "How to program C++"... I still have this book on my desk (10 years in).. Every once and a while I re-read a chapter. I'd definatly get the Code Complete, as other have suggested. Infact read that first.
To get a better understanding of object orientation, spend some time in a Smalltalk. Squeak is a free download. Then read Richard P. Gabriel's Patterns of Software and thereafter his Objects have Failed.
Thinking in C++ - Bruce Eckel
Symfonia C++ Standard - Jerzy Grębosz
If you do nothing else, program.
When you are not doing that read about programming and when something strikes you as interesting, go implement something with that knowledge. I've found that this is the only way to really set the principals.
Staying up to date on blogs can be fun, but it is scattered knowledge. It seems to distract more than help. But combined with google and a desire to research something specific can really cough up tons of information. But dont' just subscribe to alot of rss feeds and expect to get better.
I think really studying specific topics helps expand your ability. Research topics that intrigue you, meet people doing things like you (conferences, user groups, irc, facebook, stackoverflow, etc) and above all practice your art.
You can check out the Boost library and a number of the books written about it. While this may not have been what you had in mind, IMO, the Boost libraries are examples of well-designed modern C++ libraries that use the features of the language in pretty much the way they should be used to create among the most effective solutions for their problem domain. Granted of course, there are bizarre libraries like preprocessor and MPL which make you wonder if you'll ever have any use for them, but they're all round quite good. From my own experience, exploring the library and its literature has given me insight into how C++ can be used effectively.
Boost
Beyond the C++ Standard Library: An Introduction to Boost

Existing Standard Style and Coding standard documents [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 8 years ago.
Improve this question
The following have been proposed for an upcoming C++ project.
C++ Coding Standards, by Sutter and Alexandrescu
JSF Air Vehicle C++ coding standards
The Elements of C++ Style
Effective C++ 3rd Edition, by Scott Meyers
Are there other choices? Or is the list above what be should used on a C++ project?
Some related links
Do you think a software company should impose developers a coding-style?
https://stackoverflow.com/questions/66268/what-is-the-best-cc-coding-style-closed
C++ Coding Standards: 101 Rules, Guidelines, and Best Practices (C++ In-Depth Series)
by Herb Sutter and, Andrei Alexandrescu.
I really think it does not matter which one you adopt, as long as everyone goes along with it. Sometimes that can be hard as it seems that some styles don't agree with peoples tases. I.e. it comes down to arguing about whether prefixing all member variable with m_ is pretty or not.
I have been using and modifying the Geosoft standards for a while, these are for C++. There are some other at the what-is-your-favorite-coding-guidelines-checklist thread
Hmm, strange question. Just choose standard which most of the team members are familiar with. Make some kind of poll for your team. Not sure how SO can help here :)
High Integrity C++ Coding Standard Manual - Version 2.4
Try this one, it's the one that NASA's Goddard space flight centre uses.
http://software.gsfc.nasa.gov/AssetsApproved/PA2.4.1.3.pdf
I've written a coding standard for a major British company and was very conscious of putting reasons why I selected certain things rather than just make it a bunch of "Thou shalt" pronouncements. (-:
As a quick way out, I'd suggest mandating:
Scott Meyers's Effective C++ 3rd Edition (Amazon link) - if you can find a copy of the 1st edition of this book then buy it for the overview of OO design which was removed from later editions. )-:
Scott Meyer's book Effective STL (Amazon link) - you must use STL to use C++ efficiently.
Steve McConnell's book Code Complete 2 (Amazon link) - not C++ specific but full of great insights.
Coding standards are only meaningful if they help you write code. So they just need to keep your code consistent (ie if someone puts m_ for variable members and someone doesn't, it can take longer to grok the code than if they all used the same style).
That's all they (should) do, so just pick up your existing code and make sure your team codes to the same style.
I like to think of it like cartoons. If you become a cartoonist on the Simpsons, you have to draw eyes in the official way or everything looks pants, but if you go to Family Guy, you have to draw them differently. Neither way is wrong.
Too many standards are about meaningless restrictions, written by people who don't code themselves (or consider themselves too good to keep to them). Others try to teach you how to code. Neither has its place in a good standard, those just make it easier for you to look at some code and understand what its doing.
eg. my standards include rules for naming directories - you will always have your code in a directory called the same name as the project, and all binaries go in the bin subdir, with all config files in the same place, and a changelog, etc. All simple stuff, but I guarantee I'll never find a project called something different with its binaries in the root directory where I don't know what changes were made to it. Simple, easy stuff that makes a huge difference.
I agree with Harald Scheirich, it is most important to have the team agree on what the rules should be rather than just picking a set that has been recommended by outsiders.
My personal recommendation would be to read Code Complete, 2nd Edition by Steve McConnell which describes (among a whole lot of other useful stuff) several common coding standards and offers commentary on each. This might help your team in setting up your own standards.
Lockheed Martin's JSF Air Vehicle C++ Coding Standards is an interesting read but it's a bit overkill unless you're working in fields where a bug can kill people. It's still a very important example to look at from a computer ethics standpoint about an example of how to program with safety and correctness being top priority.
For general-purpose C++ coding, I'd personally recommend C++ Coding Standards by Herb Sutter. From the very beginning, it emphasizes what not to standardize (things relating to style or preference rather than practices that promote safety, correctness, efficiency). It's also among the easiest reads in your list giving very brief but concise arguments for each standard, making it something easy to show your co-workers.
Poco C++ Coding Style Guide.pdf
Apple Coding Guidelines for Cocoa
GNU Coding Standards
Bell Labs' Recommended C Style and Coding Standards
reserved names from POSIX / ISO
Facebook HHVM Coding Conventions
GeoSoft C++ Programming Style Guidelines
LLVM Coding Standards
C Style and Coding Standards for SunOS