forked from boostorg/container
Addd new constructors to containers, according to C++14's new constructors taking allocator arguments.
This commit is contained in:
1 parent
a7adc46a54
commit
22f1d32f7b
15 files changed
+349
-9
No files matched your search
@@ -201,8 +201,8 @@ class list
|
||||
: AllocHolder(a)
|
||||
{}
|
||||
|
||||
//! <b>Effects</b>: Constructs a list that will use a copy of allocator a
|
||||
//! and inserts n copies of value.
|
||||
//! <b>Effects</b>: Constructs a list
|
||||
//! and inserts n value-initialized value_types.
|
||||
//!
|
||||
//! <b>Throws</b>: If allocator_type's default constructor
|
||||
//! throws or T's default or copy constructor throws.
|
||||
@@ -212,6 +212,17 @@ class list
|
||||
: AllocHolder(Allocator())
|
||||
{ this->resize(n); }
|
||||
|
||||
//! <b>Effects</b>: Constructs a list that will use a copy of allocator a
|
||||
//! and inserts n copies of value.
|
||||
//!
|
||||
//! <b>Throws</b>: If allocator_type's default constructor
|
||||
//! throws or T's default or copy constructor throws.
|
||||
//!
|
||||
//! <b>Complexity</b>: Linear to n.
|
||||
list(size_type n, const allocator_type &a)
|
||||
: AllocHolder(a)
|
||||
{ this->resize(n); }
|
||||
|
||||
//! <b>Effects</b>: Constructs a list that will use a copy of allocator a
|
||||
//! and inserts n copies of value.
|
||||
//!
|
||||
|
||||
Reference in new issue
Block a user