MADNESS 0.10.1
Static Protected Member Functions | List of all members
madness::detail::StackBase< T, isPod > Class Template Reference

Base class for Stack which implements basic memory operations for non-POD objects. More...

#include <stack.h>

Static Protected Member Functions

static void destroy (T *first, T *last)
 Destroy a range of non-POD objects.
 
static void destroy (T *ptr)
 Destroy a non-POD object.
 
static void uninitialized_copy (T *first, T *last, T *dest)
 Copy a range of POD objects.
 
static void uninitialized_move (T *first, T *last, T *dest)
 Move a range of POD objects.
 

Detailed Description

template<typename T, bool isPod>
class madness::detail::StackBase< T, isPod >

Base class for Stack which implements basic memory operations for non-POD objects.

Template Parameters
TThe data type of the stack.
isPodAn auxiliary template parameter to select the POD/non-POD versions of this class.

Member Function Documentation

◆ destroy() [1/2]

template<typename T , bool isPod>
static void madness::detail::StackBase< T, isPod >::destroy ( T first,
T last 
)
inlinestaticprotected

Destroy a range of non-POD objects.

Parameters
[in]firstThe beginning of the range to be destroyed.
[in]lastThe end of the range to be destroyed.

References madness::detail::StackBase< T, isPod >::destroy().

◆ destroy() [2/2]

template<typename T , bool isPod>
static void madness::detail::StackBase< T, isPod >::destroy ( T ptr)
inlinestaticprotected

Destroy a non-POD object.

Parameters
[in]ptrA pointer to the object to be destroyed.

Referenced by madness::detail::StackBase< T, isPod >::destroy(), and madness::detail::StackBase< T, isPod >::uninitialized_move().

◆ uninitialized_copy()

template<typename T , bool isPod>
static void madness::detail::StackBase< T, isPod >::uninitialized_copy ( T first,
T last,
T dest 
)
inlinestaticprotected

Copy a range of POD objects.

Parameters
[in]firstThe beginning of the range to be copied.
[in]lastThe end of the range to be copied.
[in]destPointer to the uninitialized memory range.

◆ uninitialized_move()

template<typename T , bool isPod>
static void madness::detail::StackBase< T, isPod >::uninitialized_move ( T first,
T last,
T dest 
)
inlinestaticprotected

Move a range of POD objects.

Parameters
[in]firstThe beginning of the range to be moved.
[in]lastThe end of the range to be moved.
[in]destPointer to the uninitialized memory range.

References madness::detail::StackBase< T, isPod >::destroy(), and T().


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