From a1d164e6371eaf81a8aaf0be1e1a9b16a1af43fc Mon Sep 17 00:00:00 2001 From: Gertjan van den Burg Date: Tue, 6 Dec 2016 16:26:01 +0100 Subject: document undocumented elements --- include/gensvm_memory.h | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'include/gensvm_memory.h') diff --git a/include/gensvm_memory.h b/include/gensvm_memory.h index 085fcec..e5982f6 100644 --- a/include/gensvm_memory.h +++ b/include/gensvm_memory.h @@ -32,12 +32,32 @@ #include +/** + * Wrapper macro for mycalloc(). This macro uses the __FILE__ and __LINE__ + * standard macros to fill in some of the arguments to mycalloc(). This macro + * should be used when writing code, not mycalloc(). + */ #define Calloc(type, size) \ mycalloc(__FILE__, __LINE__, size, sizeof(type)) + +/** + * Wrapper macro for mymalloc(). This macro uses the __FILE__ and __LINE__ + * standard macros to fill in some of the arguments to mymalloc(). This macro + * should be used when writing code, not mymalloc(). + */ #define Malloc(type, size) \ mymalloc(__FILE__, __LINE__, (size)*sizeof(type)) +/** + * Wrapper macro for myrealloc(). This macro uses the __FILE__ and __LINE__ + * standard macros to fill in some of the arguments to myrealloc(). This macro + * should be used when writing code, not myrealloc(). + */ #define Realloc(var, type, size) \ myrealloc(__FILE__, __LINE__, (size)*sizeof(type), var) +/** + * Wrapper macro for memset(). Since memset is only used to zero a matrix, + * this macro is defined. + */ #define Memset(var, type, size) \ memset(var, 0, (size)*sizeof(type)) -- cgit v1.2.3