PureMallocator.reallocate

Standard allocator methods per the semantics defined above. The deallocate and reallocate methods are @system because they may move memory around, leaving dangling pointers in user code. Somewhat paradoxically, malloc is @safe but that's only useful to safe programs that can afford to leak memory allocated.

  1. void[] allocateZeroed(size_t bytes)
  2. bool deallocate(void[] b)
  3. bool reallocate(void[] b, size_t s)
    struct PureMallocator
    const shared pure nothrow @nogc @system
    bool
    reallocate
    (
    ref void[] b
    ,
    size_t s
    )

Meta