A new WG21 paper is available. If you are not a committee member, please use the comments section below or the std-proposals forum for public discussion.
Document number: N4166
Date: 2014-10-06
Movable initializer lists
by David Krauss
Excerpt:
Often
std::initializer_list
cannot be used, or it requires aconst_cast
hack, as it provides read-only access to its sequence. This is a consequence of the sequence potentially being shared with otherinitializer_list
objects, although often it is statically known to be uniquely local. A new initializer list class template is proposed to allow function parameters which may leverage (by overloading) or require strict ownership. Addition of this class does not impinge on the cases where the sequence should be shared. No breaking changes are proposed.
Add a Comment
Comments are closed.