![]() |
Embedded Template Library
1.0
|
Creates a variable of the specified type at the specified alignment.
class etl::type_with_alignment |
Gets a type that has the same as the specified alignment.
Public Types | |
typedef private_alignment::type_with_alignment_helper< ALIGNMENT, int_least8_t, int_least16_t, int32_t, int64_t, float, double, void * >::type | type |
struct etl::aligned_storage |
Aligned storage LENGTH should be determined in terms of sizeof()
struct etl::aligned_storage_as |
Aligned storage as
class etl::uninitialized_buffer |
Declares an aligned buffer of N_OBJECTS x of size OBJECT_SIZE at alignment ALIGNMENT.
Public Member Functions | |
template<typename T > | |
operator T& () | |
Convert to T reference. | |
template<typename T > | |
operator const T & () const | |
Convert to const T reference. | |
template<typename T > | |
operator T* () | |
Convert to T pointer. | |
template<typename T > | |
operator const T * () const | |
Convert to const T pointer. | |
Public Attributes | |
union { | |
char raw [OBJECT_SIZE *N_OBJECTS] | |
etl::type_with_alignment< ALIGNMENT >::type etl_alignment_type | |
}; | |
Static Public Attributes | |
static ETL_CONSTANT size_t | OBJECT_SIZE = OBJECT_SIZE_ |
static ETL_CONSTANT size_t | N_OBJECTS = N_OBJECTS_ |
static ETL_CONSTANT size_t | ALIGNMENT = ALIGNMENT_ |
class etl::uninitialized_buffer_of |
Declares an aligned buffer of N_OBJECTS as if they were type T.
Public Types | |
typedef T | value_type |
typedef T & | reference |
typedef const T & | const_reference |
typedef T * | pointer |
typedef const T * | const_pointer |
typedef T * | iterator |
typedef const T * | const_iterator |
Public Member Functions | |
T & | operator[] (int i) |
Index operator. | |
const T & | operator[] (int i) const |
Index operator. | |
operator T& () | |
Convert to T reference. | |
operator const T & () const | |
Convert to const T reference. | |
operator T* () | |
Convert to T pointer. | |
operator const T * () const | |
Convert to const T pointer. | |
T * | begin () |
const T * | begin () const |
T * | end () |
const T * | end () const |
Public Attributes | |
union { | |
char raw [sizeof(T) *N_OBJECTS] | |
etl::type_with_alignment< ALIGNMENT >::type etl_alignment_type | |
}; | |
Static Public Attributes | |
static ETL_CONSTANT size_t | OBJECT_SIZE = sizeof(T) |
static ETL_CONSTANT size_t | N_OBJECTS = N_OBJECTS_ |
static ETL_CONSTANT size_t | ALIGNMENT = etl::alignment_of<T>::value |