![]() |
Stan
2.5.0
probability, sampling & optimization
|
(Expert) Allocate, free, and manage underlying system memory. More...
Classes | |
| class | stack_alloc |
| An instance of this class provides a memory pool through which blocks of raw memory may be allocated and then collected simultaneously. More... | |
Functions | |
| template<typename T > | |
| bool | is_aligned (T *ptr, unsigned int bytes_aligned) |
Return true if the specified pointer is aligned on the number of bytes. More... | |
(Expert) Allocate, free, and manage underlying system memory.
| bool stan::memory::is_aligned | ( | T * | ptr, |
| unsigned int | bytes_aligned | ||
| ) |
Return true if the specified pointer is aligned on the number of bytes.
This doesn't really make sense other than for powers of 2.
| ptr | Pointer to test. |
| bytes_aligned | Number of bytes of alignment required. |
true if pointer is aligned. | Type | of object to which pointer points. |
Definition at line 32 of file stack_alloc.hpp.