MCPcopy Create free account
hub / github.com/Gecode/gecode / allocate

Method allocate

gecode/kernel/memory/allocators.hpp:244–246  ·  view source on GitHub ↗

* \brief Allocates storage * * Returns a pointer to the first element in a block of storage * count*sizeof(T) bytes in size. The block is aligned * appropriately for objects of type \a T. Throws the exception * \a bad_alloc if the storage is unavailable. */

Source from the content-addressed store, hash-verified

242 * \a bad_alloc if the storage is unavailable.
243 */
244 pointer allocate(size_type count) {
245 return static_cast<pointer>(space.ralloc(sizeof(T)*count));
246 }
247
248 /**
249 * \brief Allocates storage

Callers

nothing calls this directly

Calls 1

rallocMethod · 0.45

Tested by

no test coverage detected