Share via


allocator<void> 클래스

이 컨텍스트에서 적합한 형식을 정의하는 형식 void에 대한 클래스 템플릿 할당자의 특수화입니다.

구문

template <>
class allocator<void> {
    typedef void *pointer;
    typedef const void *const_pointer;
    typedef void value_type;
    template <class Other>
    struct rebind;
    allocator();
    allocator(const allocator<void>&);

    template <class Other>
    allocator(const allocator<Other>&);

    template <class Other>
    allocator<void>& operator=(const allocator<Other>&);
};

설명

클래스는 형식void에 대한 클래스 템플릿 할당자를 명시적으로 특수화합니다. 해당 생성자 및 대입 연산자는 클래스 템플릿과 동일하게 동작하지만 다음 형식만 정의합니다.