21 #define ALLOCATOR_HPP 1
47 typedef const T* const_pointer;
49 typedef const T& const_reference;
50 typedef std::size_t size_type;
51 typedef std::ptrdiff_t difference_type;
60 pointer address (reference value)
const {
63 const_pointer address (const_reference value)
const {
81 size_type max_size ()
const throw() {
82 return std::numeric_limits<std::size_t>::max() /
sizeof(T);
86 pointer allocate (size_type num,
const void* = 0) {
91 void construct (pointer p,
const T& value) {
97 void destroy (pointer p) {
103 void deallocate (pointer p, size_type num) {
109 template <
typename T1,
typename T2>
114 template <
typename T1,
typename T2>
115 bool operator!= (
const Allocator<T1>&,
116 const Allocator<T2>&) throw() {
121 #endif // ALLOCATOR_HPP