MRPT  1.9.9
xsmalloc.h
Go to the documentation of this file.
1 /* +------------------------------------------------------------------------+
2  | Mobile Robot Programming Toolkit (MRPT) |
3  | https://www.mrpt.org/ |
4  | |
5  | Copyright (c) 2005-2019, Individual contributors, see AUTHORS file |
6  | See: https://www.mrpt.org/Authors - All rights reserved. |
7  | Released under BSD License. See: https://www.mrpt.org/License |
8  +------------------------------------------------------------------------+ */
9 #ifndef XSMALLOC_H
10 #define XSMALLOC_H
11 
12 #include <stddef.h>
13 #include "xstypesconfig.h"
14 
15 #ifdef __cplusplus
16 extern "C"
17 {
18 #endif
19 
20  XSTYPES_DLL_API void* xsMalloc(size_t sz);
21  XSTYPES_DLL_API void* xsRealloc(void* ptr, size_t sz);
22  XSTYPES_DLL_API void xsFree(void* ptr);
23 
24  XSTYPES_DLL_API void* xsAlignedMalloc(size_t sz);
25  XSTYPES_DLL_API void* xsAlignedRealloc(void* ptr, size_t sz);
26  XSTYPES_DLL_API void xsAlignedFree(void* ptr);
27 
28 #ifndef xsMathMalloc
29 #define xsMathMalloc(n) xsAlignedMalloc(n)
30 #endif
31 
32 #ifndef xsMathRealloc
33 #define xsMathRealloc(p, n) xsAlignedRealloc(p, n)
34 #endif
35 
36 #ifndef xsMathFree
37 #define xsMathFree(p) xsAlignedFree(p)
38 #endif
39 
40 #ifdef __cplusplus
41 } // extern "C"
42 #endif
43 
44 #endif // XSMALLOC_H
XSTYPES_DLL_API void * xsAlignedMalloc(size_t sz)
XSTYPES_DLL_API void * xsMalloc(size_t sz)
XSTYPES_DLL_API void * xsAlignedRealloc(void *ptr, size_t sz)
XSTYPES_DLL_API void xsFree(void *ptr)
#define XSTYPES_DLL_API
Definition: xstypesconfig.h:9
XSTYPES_DLL_API void * xsRealloc(void *ptr, size_t sz)
XSTYPES_DLL_API void xsAlignedFree(void *ptr)



Page generated by Doxygen 1.8.14 for MRPT 1.9.9 Git: 8fe78517f Sun Jul 14 19:43:28 2019 +0200 at lun oct 28 02:10:00 CET 2019