STAPL API Reference          
Overview   Containers   Algorithms   Views   Skeletons   Run-Time System
Modules     Classes    
List of all members | Classes | Public Member Functions | Public Types
stapl::runtime::malloc_allocator< T > Class Template Reference

An allocator that uses std::malloc() directly. More...

Classes

struct  rebind
 Provides a way to obtain an allocator for a different type. More...
 

Public Member Functions

 malloc_allocator (malloc_allocator const &) noexcept=default
 
template<typename U >
 malloc_allocator (malloc_allocator< U > const &) noexcept
 
pointer address (reference x) const noexcept
 
const_pointer address (const_reference x) const noexcept
 
pointer allocate (size_type n, malloc_allocator< void >::const_pointer=0)
 
void deallocate (pointer p, size_type)
 
size_type max_size (void) const noexcept
 
void construct (pointer p, const_reference val)
 
void destroy (pointer p)
 
template<typename U , typename... Args>
void construct (U *p, Args &&... args)
 
template<typename U >
void destroy (U *p)
 

Public Types

typedef std::size_t size_type
 
typedef std::ptrdiff_t difference_type
 
typedef T * pointer
 
typedef const T * const_pointer
 
typedef T & reference
 
typedef T const & const_reference
 
typedef T value_type
 

Detailed Description

template<typename T>
class stapl::runtime::malloc_allocator< T >

An allocator that uses std::malloc() directly.

See The C++ Programming Language, 3rd edition 19.4 and C++11 Draft 20.9.5


The documentation for this class was generated from the following file: