Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Stdcxx Wiki" for change 
notification.

The following page has been changed by EricLemings:
http://wiki.apache.org/stdcxx/Cpp0x

The comment on the change is:
Added a few quick notes on tuples.

------------------------------------------------------------------------------
  Note, this is not a complete list of C++0x features: these are only the 
components that fall within the scope of this development plan.  Also, the last 
two components -- atomic operations and multithread support -- are not planned 
until the 5.0 release timeframe.
  
  
+ = Tuples =
+ 
+ Tuples are basically the same thing as {{{std::pair}}} except that tuples 
have a variable number of type parameters (or an implementation-defined number 
of parameters with default types) .  The class template and associated 
{{{std}}} namespace members are sufficiently simple enough so that two 
implementations -- one for compilers that support variadic templates and 
another for all other compilers that don't -- can be written at the same time.
+ 
+ A couple of things to take into consideration however.  Tuples can have no 
type parameters; e.g., {{{std::tuple<>}}} is a valid type.  Consequently, this 
particular tuple type should have no constructors that accept (or other members 
that operate on) any values (other than the value of the tuple itself).
+ 
+ Tuples with exactly two type parameters have conditional constructors and 
operators for conversions from values of the {{{std::pair}}} class template.  
This means the class template needs to be specialized when instantiated with 
exactly two types to define the additional members.
+ 
+ 
  = Online Resources =
  
   * [http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2005/n1836.pdf ISO/IEC 
TR 19768: C++ Library Extensions TR1].  The original draft specification.  (Now 
obsolete since modifications have been made in the latest C++ draft standard.)

Reply via email to