allocator_traits::construct 메서드
Static method that uses a specified allocator to construct an object.
template<class Uty, class Types>
static void construct(Alloc& al, Uty *ptr, Types&&... args);
매개 변수
al
An allocator object.ptr
A pointer to the location where the object is to be constructed.args
A list of arguments that is passed to the object constructor.
설명
The static member function calls al.construct(ptr, args...), if that expression is well formed; otherwise it evaluates ::new (static_cast<void *>(ptr)) Uty(std::forward<Types>(args)...).
요구 사항
헤더 <memory>
네임스페이스: std