tmp/tmpvnmo5mwk/{from.md → to.md}
RENAMED
|
@@ -1,6 +1,6 @@
|
|
| 1 |
-
####
|
| 2 |
|
| 3 |
``` cpp
|
| 4 |
iterator insert(const_iterator position, const T& x);
|
| 5 |
iterator insert(const_iterator position, T&& x);
|
| 6 |
iterator insert(const_iterator position, size_type n, const T& x);
|
|
@@ -25,16 +25,16 @@ has no effect on the validity of references to elements of the deque.
|
|
| 25 |
|
| 26 |
*Remarks:* If an exception is thrown other than by the copy constructor,
|
| 27 |
move constructor, assignment operator, or move assignment operator of
|
| 28 |
`T` there are no effects. If an exception is thrown while inserting a
|
| 29 |
single element at either end, there are no effects. Otherwise, if an
|
| 30 |
-
exception is thrown by the move constructor of a
|
| 31 |
-
`T`, the effects are unspecified.
|
| 32 |
|
| 33 |
*Complexity:* The complexity is linear in the number of elements
|
| 34 |
inserted plus the lesser of the distances to the beginning and end of
|
| 35 |
-
the deque. Inserting a single element
|
| 36 |
a deque always takes constant time and causes a single call to a
|
| 37 |
constructor of `T`.
|
| 38 |
|
| 39 |
``` cpp
|
| 40 |
iterator erase(const_iterator position);
|
|
@@ -59,9 +59,8 @@ operations. — *end note*]
|
|
| 59 |
as the number of elements erased, but the number of calls to the
|
| 60 |
assignment operator of `T` is no more than the lesser of the number of
|
| 61 |
elements before the erased elements and the number of elements after the
|
| 62 |
erased elements.
|
| 63 |
|
| 64 |
-
*Throws:* Nothing unless an exception is thrown by the
|
| 65 |
-
|
| 66 |
-
`T`.
|
| 67 |
|
|
|
|
| 1 |
+
#### Modifiers <a id="deque.modifiers">[[deque.modifiers]]</a>
|
| 2 |
|
| 3 |
``` cpp
|
| 4 |
iterator insert(const_iterator position, const T& x);
|
| 5 |
iterator insert(const_iterator position, T&& x);
|
| 6 |
iterator insert(const_iterator position, size_type n, const T& x);
|
|
|
|
| 25 |
|
| 26 |
*Remarks:* If an exception is thrown other than by the copy constructor,
|
| 27 |
move constructor, assignment operator, or move assignment operator of
|
| 28 |
`T` there are no effects. If an exception is thrown while inserting a
|
| 29 |
single element at either end, there are no effects. Otherwise, if an
|
| 30 |
+
exception is thrown by the move constructor of a
|
| 31 |
+
non-*Cpp17CopyInsertable* `T`, the effects are unspecified.
|
| 32 |
|
| 33 |
*Complexity:* The complexity is linear in the number of elements
|
| 34 |
inserted plus the lesser of the distances to the beginning and end of
|
| 35 |
+
the deque. Inserting a single element at either the beginning or end of
|
| 36 |
a deque always takes constant time and causes a single call to a
|
| 37 |
constructor of `T`.
|
| 38 |
|
| 39 |
``` cpp
|
| 40 |
iterator erase(const_iterator position);
|
|
|
|
| 59 |
as the number of elements erased, but the number of calls to the
|
| 60 |
assignment operator of `T` is no more than the lesser of the number of
|
| 61 |
elements before the erased elements and the number of elements after the
|
| 62 |
erased elements.
|
| 63 |
|
| 64 |
+
*Throws:* Nothing unless an exception is thrown by the assignment
|
| 65 |
+
operator of `T`.
|
|
|
|
| 66 |
|