Update example
This commit is contained in:
1 parent
1f2584ccea
commit
93112a5a7c
2 files changed
+4
-4
No files matched your search
+2
-2
@@ -47,8 +47,8 @@ static void my_array_free(void *ptr)
|
|||||||
# define M_MEMORY_DEL(ptr) my_free(ptr, sizeof *ptr)
|
# define M_MEMORY_DEL(ptr) my_free(ptr, sizeof *ptr)
|
||||||
|
|
||||||
// Allocate for array of objects
|
// Allocate for array of objects
|
||||||
# define M_MEMORY_REALLOC(type, ptr, n) my_array_alloc (sizeof (type), ptr, n)
|
# define M_MEMORY_REALLOC(type, ptr, o, n) my_array_alloc (sizeof (type), ptr, n)
|
||||||
# define M_MEMORY_FREE(ptr) my_array_free(ptr)
|
# define M_MEMORY_FREE(type, ptr, n) my_array_free(ptr)
|
||||||
|
|
||||||
#include "m-list.h"
|
#include "m-list.h"
|
||||||
#include "m-array.h"
|
#include "m-array.h"
|
||||||
|
|||||||
+2
-2
@@ -76,8 +76,8 @@ static void my_array_free(void *ptr)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Allocate for array of objects
|
// Allocate for array of objects
|
||||||
# define MY_MEMORY_REALLOC(type, ptr, n) my_array_alloc (sizeof (type), ptr, n)
|
# define MY_MEMORY_REALLOC(type, ptr, o, n) my_array_alloc (sizeof (type), ptr, n)
|
||||||
# define MY_MEMORY_FREE(ptr) my_array_free(ptr)
|
# define MY_MEMORY_FREE(type, ptr, n) my_array_free(ptr)
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user