- Added nth and index_of.

- Used BOOST_MOVE_BASE
This commit is contained in:
Ion Gaztañaga committed 2014-11-01 20:03:25 +01:00
1 parent 6d034733bd
commit 6f1f162cb3
21 files changed
+615 -106

No files matched your search

+6 -6
View File
@@ -259,13 +259,13 @@ class list
: AllocHolder(x)
{ this->insert(this->cbegin(), x.begin(), x.end()); }
//! <b>Effects</b>: Move constructor. Moves mx's resources to *this.
//! <b>Effects</b>: Move constructor. Moves x's resources to *this.
//!
//! <b>Throws</b>: If allocator_type's copy constructor throws.
//!
//! <b>Complexity</b>: Constant.
list(BOOST_RV_REF(list) x)
: AllocHolder(boost::move(static_cast<AllocHolder&>(x)))
: AllocHolder(BOOST_MOVE_BASE(AllocHolder, x))
{}
//! <b>Effects</b>: Copy constructs a list using the specified allocator.
@@ -280,7 +280,7 @@ class list
{ this->insert(this->cbegin(), x.begin(), x.end()); }
//! <b>Effects</b>: Move constructor sing the specified allocator.
//! Moves mx's resources to *this.
//! Moves x's resources to *this.
//!
//! <b>Throws</b>: If allocation or value_type's copy constructor throws.
//!
@@ -786,7 +786,7 @@ class list
void push_front(const T &x);
//! <b>Effects</b>: Constructs a new element in the beginning of the list
//! and moves the resources of mx to this new element.
//! and moves the resources of x to this new element.
//!
//! <b>Throws</b>: If memory allocation throws.
//!
@@ -806,7 +806,7 @@ class list
void push_back(const T &x);
//! <b>Effects</b>: Constructs a new element in the end of the list
//! and moves the resources of mx to this new element.
//! and moves the resources of x to this new element.
//!
//! <b>Throws</b>: If memory allocation throws.
//!
@@ -830,7 +830,7 @@ class list
//! <b>Requires</b>: p must be a valid iterator of *this.
//!
//! <b>Effects</b>: Insert a new element before p with mx's resources.
//! <b>Effects</b>: Insert a new element before p with x's resources.
//!
//! <b>Returns</b>: an iterator to the inserted element.
//!