MCPcopy Create free account
hub / github.com/ezrosent/allocators-rs / c_calloc

Method c_calloc

malloc-bind/src/lib.rs:241–257  ·  view source on GitHub ↗

The C `calloc` function. `calloc` allocates storage sufficient to hold `nmemb` elements of size `size` and returns a pointer to it. The allocated memory is aligned to `MIN_ALIGN`. The memory is initialized to zero. If there is insufficient space to perform the allocation, `errno` is set to `ENOMEM` and the return value is `NULL`. # Platform-specific behavior On Linux, if either `size` or `nmemb

(&self, nmemb: size_t, size: size_t)

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers

nothing calls this directly

Implementers 1

alloc_impl.rselfmalloc/src/alloc_impl.rs

Calls 6

unlikelyFunction · 0.85
roundupFunction · 0.85
layout_from_size_alignFunction · 0.85
alloc_zeroedMethod · 0.80
insert_layoutMethod · 0.80
cloneMethod · 0.45

Tested by

no test coverage detected