diff options
author | Tomasz Konojacki <me@xenu.pl> | 2022-05-16 20:26:16 +0200 |
---|---|---|
committer | xenu <me@xenu.pl> | 2022-05-17 20:43:37 +0200 |
commit | c372fad01ad7428f1574b75cfb81a596aad45953 (patch) | |
tree | b6546ee68fa3c694f17ae0b739b2ce08f5b5920d /handy.h | |
parent | 72c1cbb43c4dc5b9392f0508fdd67dc71ce4d215 (diff) | |
download | perl-c372fad01ad7428f1574b75cfb81a596aad45953.tar.gz |
perlapi: document safe(?:c|re|m)alloc
They're widely used on CPAN, especially safemalloc.
Diffstat (limited to 'handy.h')
-rw-r--r-- | handy.h | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -2520,6 +2520,8 @@ typedef U32 line_t; =for apidoc_section $memory =for apidoc Am|void|Newx|void* ptr|int nitems|type +=for apidoc_item |void*|safemalloc|void *ptr + The XSUB-writer's interface to the C C<malloc> function. Memory obtained by this should B<ONLY> be freed with L</"Safefree">. @@ -2537,12 +2539,16 @@ cast. See also C<L</Newx>>. Memory obtained by this should B<ONLY> be freed with L</"Safefree">. =for apidoc Am|void|Newxz|void* ptr|int nitems|type +=for apidoc_item |void*|safecalloc|size_t nitems|size_t item_size + The XSUB-writer's interface to the C C<malloc> function. The allocated memory is zeroed with C<memzero>. See also C<L</Newx>>. Memory obtained by this should B<ONLY> be freed with L</"Safefree">. =for apidoc Am|void|Renew|void* ptr|int nitems|type +=for apidoc_item |void*|saferealloc|void *ptr|size_t size + The XSUB-writer's interface to the C C<realloc> function. Memory obtained by this should B<ONLY> be freed with L</"Safefree">. |