When Will C++0X Be Finished

When will C++0x be finished?

As Howard already said in the question, the final draft was completed on March 25, 2011.

There will now be some months of editorial changes, voting and ISO red tape before it officially becomes a standard, but on the 25th, the standards committee themselves officially signed off on it.

Sources:

https://www.ibm.com/developerworks/mydeveloperworks/blogs/5894415f-be62-4bc0-81c5-3956e82276f3/entry/the_c_0x_standard_has_been_approved_to_ship23?lang=en

http://herbsutter.com/2011/03/25/we-have-fdis-trip-report-march-2011-c-standards-meeting/

http://twitter.com/#!/sdt_intel/status/51328822066417665

and of course, Howard Hinnant, who asked the question, is on the committee as well, so he's not making it up.

(Only posting this as a "real" answer because Howard apparently was unable to answer his own question)

Edit
And as of September 1st, 2011, C++11 has been published by ISO. It doesn't get any more official than that. We have a new standard.

When will C++0x be released?

Edit: We have a new standard now : http://herbsutter.com/2011/08/12/we-have-an-international-standard-c0x-is-unanimously-approved/


Edit: The FDIS is done, so officially it should be released in few months. See : http://herbsutter.com/2011/03/25/we-have-fdis-trip-report-march-2011-c-standards-meeting/


Herb Sutter is a useful source of information on this as the convener of then ISO C++ committee (until recently).

EDIT
See his latest blog post here from March 13, 2010 for an update on recent progress: C++0x is now a Final Committee Draft, and...

"... assuming all goes well , C++0x could officially be published as soon as next year as ISO C++ 2011, and we can stop with the “x-is-hex” jokes and just start calling it C++11."

P.J. Plauger has taken over as the new convener, but I expect that Herb will continue to provide updates on the committee's progress - and as Herb also works for Microsoft, early clues as to when a Microsoft implementation of C++0X will be available.

C++0X when?

UPDATE : years later...

The last Draft have been officially finalized few weeks ago, in Mars 2011 and will be officially out around July 2011. The name of the new standard would be C++2011 : http://herbsutter.com/2011/03/25/we-have-fdis-trip-report-march-2011-c-standards-meeting/

Microsoft C++ compiler (VC10) provide C++0x features (lambda, decltype, auto, r-value reference and nullptr). GCC provide a work in progress version that already implements a lot of features (see http://gcc.gnu.org/projects/cxx0x.html).
Comeau C++ seems to be more advanced. CLang started to provide some features but not much for the moment (see http://clang.llvm.org/cxx_status.html )

So, most of the features are be availables for the main c++ compilers at the time the ISO administration officially validate the draft. Some advanced features are still not be available before some years I guess.

C++0x will no longer have concepts. Opinions? How will this affect you?

Personally I'm not too unhappy of the removal as the purpose of concepts were to mainly improve compile time error messages, as Jeremy Siek, one of the co-authors of the Concepts proposal, writes (http://lambda-the-ultimate.org/node/3518#comment-50071):

While the Concepts proposal was not
perfect (can any extension to C++
really ever be perfect?), it would
have provided a very usable and
helpful extension to the language, an
extension that would drastically
reduce the infamous error messages
that current users of template
libraries are plagued with.

Of course concepts had more purpose than just enable the compilers to give shorter error messages, but currently I think we all can live without them.

EDIT: Herb Sutter also writes on his blog:

Q: Wasn’t this C++0x’s one big
feature?

A: No. Concepts would be great, but
for most users, the presence or
absence of concepts will make no
difference to their experience with
C++0x except for quality of error
messages.

Q: Aren’t concepts about adding major
new expressive power to the language,
and so enable major new kinds of
programs or programming styles?

A: Not really. Concepts are almost
entirely about getting better error
messages.

Have You Started Using C++0x?

C++0x is not a completed standard yet.
It's likely that there will be many revisions before an international accepted standard is released.
So it all depends, what are you writing code for? If it's for an work-assignment i would stick with regular C++, wait for the standard to be set and give the programming community the time it takes to adjust. Don't refactor code you really need to implement, it might give you a loot of trouble.

I however think C++0x great to play around with and also it can't hurt to be familiar with the syntax when 0x is globally accepted.

What is the difference between C++0x and C++11?

C++ and C Standards are usually named after the year they are published in, which makes it easier to remember by.

For example, in C++, the original Standard was published in 1998, so we talk about C++98, and when we refer to its first correction, published in 2003, we talk about C++03.

It had been purported that the next Standard after would be done for 2008, but since it was uncertain, it was dubbed C++0x, where the x stood for either 8 or 9. In practice though, as we all know, the planning shifted and so we end-up with C++11.

Still, for the next version (C++1x), Bjarne Stroustrup stated his intent to do it in 5 years (so about 2016). For now, there are changes envisionned to the core language (concepts, modules and garbage collection), and the focus seems to be more on extending the library (filesystem for example), but it's still early so who knows!

C++ Modules - why were they removed from C++0x? Will they be back later on?

From the State of C++ Evolution (Post San Francisco 2008), the Modules proposal was categorized as "Heading for a separate TR:"

These topics are deemed too important to wait for another standard after C++0x before being published, but too experimental to be finalised in time for the next Standard. Therefore, these features will be delivered by a technical report at the earliest opportunity.

The modules proposal just wasn't ready and waiting for it would have delayed finishing the C++0x standard. It wasn't really removed, it was just never incorporated into the working paper.

What do 0LL or 0x0UL mean?

These are constants in C and C++. The suffix LL means the constant is of type long long, and UL means unsigned long.

In general, each L or l represents a long and each U or u represents an unsigned. So, e.g.

1uLL

means the constant 1 with type unsigned long long.

This also applies to floating point numbers:

1.0f    // of type 'float'
1.0 // of type 'double'
1.0L // of type 'long double'

and strings and characters, but they are prefixes:

 'A'   // of type 'char'
L'A' // of type 'wchar_t'
u'A' // of type 'char16_t' (C++0x only)
U'A' // of type 'char32_t' (C++0x only)

In C and C++ the integer constants are evaluated using their original type, which can cause bugs due to integer overflow:

long long nanosec_wrong = 1000000000 * 600;
// ^ you'll get '-1295421440' since the constants are of type 'int'
// which is usually only 32-bit long, not big enough to hold the result.

long long nanosec_correct = 1000000000LL * 600;
// ^ you'll correctly get '600000000000' with this

int secs = 600;
long long nanosec_2 = 1000000000LL * secs;
// ^ use the '1000000000LL' to ensure the multiplication is done as 'long long's.

In Google Go, all integers are evaluated as big integers (no truncation happens),

    var nanosec_correct int64 = 1000000000 * 600

and there is no "usual arithmetic promotion"

    var b int32 = 600
var a int64 = 1000000000 * b
// ^ cannot use 1000000000 * b (type int32) as type int64 in assignment

so the suffixes are not necessary.

Compiler support for upcoming C++0x

The only compiler that has an implementation of concepts is conceptgcc (and even that is incomplete - but it is good enough to get a good feel for the feature).

Visual C++ 2010 Beta has some useful C++0x support - you can play with lambdas, rvalue references, auto, decltype.

Comeau C++ or the EDG based compilers are surprisingly not as advanced I would have expected them to be in their implementation of C++0x.

GCC 4.4 (variadic templates, initializer lists, inline namespaces, autor, decltype) probably has the most features implemented out of any of the other compilers, but is lagging in concepts and lambdas (separate branch development is ongoing).

Side effects of enabling C++0x support in gcc

The C++0x support has been, and is under heavy development. One thing this means is that bugs get fixed quickly, another thing it means is that there might be small bugs present. I say small, because of two reasons:

  1. libstdc++ has not been rewritten from scratch, so all the old elements are just as stable as it was before any of this c++0x was available, if not more stable, because of several years of bug fixes.

  2. There's corner cases in the new/old Standard that haven't yet been ironed out. Are these the runtime quirks you talk about? No. C++0x support has been under development for 4 releases now, don't worry.

Most of the impact from that flag will be felt in the new language features, the library features like move constructors and std::thread (on posix platforms) don't affect code not using them.

Bottom line, experimental is too strict a word in daily production. The standard has changed in the three/four years GCC has been working on support. Old revisions of c++0x will be broken in a newer GCC, but that's a good thing. C++0x is finished as far as the non-paying-for-a-pdf-world is concerned, so no breaking changes should be added. Decide if you want the new stuff or not beforehand, because you won't be able to jsut switch it off once you've gotten used to using it.



Related Topics



Leave a reply



Submit