Created on 2024-08-26.00:00:00 last changed yesterday
Proposed resolution:
This wording is relative to N4988.
Modify [sequence.reqmts] as indicated:
a.emplace(p, args)-19- Result: iterator.
-20- Preconditions: T is Cpp17EmplaceConstructible into X from args. For vector, inplace_vector, and deque, T is also Cpp17MoveInsertable into X and Cpp17MoveAssignable. -21- Effects: Inserts an object of type T constructed with std::forward<Args>(args)... before p. [Note 1: args can directly or indirectly refer to a value in a. — end note] -22- Returns: An iterator that points to the new element constructed from args into a.
[ 2024-09-18; Reflector poll ]
Set status to Tentatively Ready after nine votes in favour during reflector poll.
Inserting into the middle of an inplace_vector, just like inserting into the middle of a vector or deque, requires that we construct the new element out-of-line, shift down the trailing elements (Cpp17MoveAssignable), and then move-construct the new element into place (Cpp17MoveInsertable). P0843R14 failed to make this change, but it should have.
History | |||
---|---|---|---|
Date | User | Action | Args |
2024-11-19 16:09:07 | admin | set | status: ready -> voting |
2024-09-18 22:30:36 | admin | set | messages: + msg14384 |
2024-09-18 22:30:36 | admin | set | status: new -> ready |
2024-09-01 08:46:08 | admin | set | messages: + msg14353 |
2024-08-26 00:00:00 | admin | create |