close
Пространства имён
Варианты
Действия

std::stack::emplace

Материал из cppreference.com

<metanoindex/>

 
 
 
 
<tbody> </tbody>
template< class... Args > void emplace( Args&&... args );
(начиная с C++11)

Pushes new element on top of the stack. The element is constructed in-place, i.e. no copy or move operations are performed. The constructor of the element is called with exactly the same arguments, as supplied to the function.

Effectively calls c.emplace_back(std::forward<Args>(args)...)

Параметры

args
Аргументы направить в конструкторе элемента
Оригинал:
arguments to forward to the constructor of the element
Текст был переведён автоматически используя Переводчик Google.
Вы можете проверить и исправить перевод. Для инструкций щёлкните сюда.

Возвращаемое значение

(Нет)

Сложность

Такая же, как сложность Container::emplace_back.

См. также

вставляет элемент на вершину
(public функция-элемент) [править]
удаляет элемент с вершины
(public функция-элемент) [править]