ALib C++ Library
Library Version: 2402 R1
Documentation generated by doxygen
No Matches
alib::boxing::detail Namespace Reference


This namespace implements internals of namespace alib::boxing.

Type Index:

struct  BoxesAllocator
struct  DbgStringTable
struct  FunctionTable
struct  StructArray
struct  T_VTableFactory
struct  TArrayOf
struct  TDefaultBoxing
struct  TNotBoxable
struct  TPlain
union  UnionFloatingPoints
union  UnionIntegrals
union  UnionPointers
struct  VTable
class  VTableTT

Function Index:

ALIB_API void DbgCheckIsInitialized ()
ALIB_API void DbgCheckRegistration (detail::VTable *vtable, bool increaseUsageCounter)
void DbgRegisterVTable (detail::VTable *vtable, detail::VTable::DbgFactoryType productionType)
ALIB_API char * monoAlloc (monomem::MonoAllocator &allocator, size_t size, size_t alignment)

Variable Index:


Function Details:

◆ DbgCheckIsInitialized()

void DbgCheckIsInitialized ( )

Checks if ALib Boxing was correctly initialized. This is done with the creation of dynamic vtables, to detect global or static box objects which are initialized with data that is mapped to a type that no static vtable is defined for.

Available and used only in debug-compilations.

See also
Manual chapter 12.4 Global And Static Box Instances And Their Initialization.

Definition at line 1121 of file boxing.cpp.

◆ DbgCheckRegistration()

void DbgCheckRegistration ( detail::VTable * vtable,
bool increaseUsageCounter )

Checks for doubly-defined vtables, as well as for unregistered static vtables.

Available and used only in debug-compilations.

vtableThe vtable to check.
increaseUsageCounterDenotes if this is a use of the vtable or just a check.

Definition at line 1130 of file boxing.cpp.

Here is the call graph for this function:

◆ DbgRegisterVTable()

ALIB_API void DbgRegisterVTable ( detail::VTable * vtable,
detail::VTable::DbgFactoryType productionType )

Registers a virtual table for debug purposes. This function is invoked internally, when a dynamic vtable is created and when a static vtable is registered.

Statically created vtables have to be registered during bootstrap in debug-compilations. For this, macro ALIB_BOXING_BOOTSTRAP_VTABLE_DBG_REGISTER is available, which is empty in release compilations.

See also
Macros ALIB_BOXING_VTABLE_DECLARE and Programmer's Manual chapter 12.2 Optimizations With Static VTables.
vtableThe vtable to register.
productionTypeDenotes whether the vtable is a static constexpr object or dynamically created from template type VTableTT.

Definition at line 96 of file dbgboxing.cpp.

Here is the call graph for this function:

◆ monoAlloc()

ALIB_API char * monoAlloc ( monomem::MonoAllocator & allocator,
size_t size,
size_t alignment )

This detail namespace function just calls MonoAllocator::Alloc with the given parameters. The use of this function avoids the need to include headers of module ALib Monomem , by headers of module ALib Boxing .

allocatorThe allocator to use.
sizeThe requested size.
alignmentThe requested alignment
The allocated piece of memory.

Definition at line 46 of file boxes.cpp.

Here is the call graph for this function:

Variable Details:



The default box-functions set.

Definition at line 128 of file vtable.cpp.