malloc package:gi-glib
Allocates
nBytes bytes of memory. If
nBytes is 0 it returns
Nothing.
If the allocation fails (because the system is out of memory), the
program is terminated.
Allocates
nBytes bytes of memory, initialized to 0's.
If
nBytes is 0 it returns
Nothing.
If the allocation fails (because the system is out of memory), the
program is terminated.
This function is similar to
malloc0, allocating
(
nBlocks *
nBlockBytes) bytes, but
care is taken to detect possible overflow during multiplication.
If the allocation fails (because the system is out of memory), the
program is terminated.
Since: 2.24
This function is similar to
malloc, allocating
(
nBlocks *
nBlockBytes) bytes, but
care is taken to detect possible overflow during multiplication.
If the allocation fails (because the system is out of memory), the
program is terminated.
Since: 2.24
Type for the callback on the (unwrapped) C side.
Type for the callback on the (unwrapped) C side.
No description available in the introspection data.
No description available in the introspection data.
Given a pointer to a foreign C function, wrap it into a function
callable from Haskell.
Given a pointer to a foreign C function, wrap it into a function
callable from Haskell.
No description available in the introspection data.
Deprecated: (Since version 2.46)GLib always uses the system malloc,
so this function alwaysreturns True.
Attempts to allocate
nBytes, and returns
Nothing on failure. Contrast with
malloc, which aborts
the program on failure.
Attempts to allocate
nBytes, initialized to 0's, and
returns
Nothing on failure. Contrast with
malloc0, which
aborts the program on failure.
Since: 2.8
This function is similar to
tryMalloc0, allocating
(
nBlocks *
nBlockBytes) bytes, but
care is taken to detect possible overflow during multiplication.
Since: 2.24
This function is similar to
tryMalloc, allocating
(
nBlocks *
nBlockBytes) bytes, but
care is taken to detect possible overflow during multiplication.
Since: 2.24