CloverBootloader/rEFIt_UEFI/PlatformPOSIX/include/XToolsConf.h

35 lines
821 B
C
Raw Normal View History

2020-04-26 15:07:30 +02:00
#ifndef __XTOOLSCONF_H__
#define __XTOOLSCONF_H__
#include <posix/posix.h>
#define xsize size_t
//#define xisize INTN
2020-04-25 11:59:07 +02:00
#ifdef _MSC_VER
#define MAX_XSIZE SIZE_MAX
#else
#define MAX_XSIZE SIZE_T_MAX
2020-04-25 11:59:07 +02:00
#endif
//#define MAX_XISIZE MAX_INTN
#define XStringGrowByDefault 16
#define XArrayGrowByDefault 16
2020-08-13 14:07:40 +02:00
#define XBufferGrowByDefault 16
/* For convience, operator [] is define with int parameter.
2020-04-24 11:30:09 +02:00
* Defining __XTOOLS_CHECK_OVERFLOW__ make a check that the parameter is >= 0
* TODO : make new XString using __XTOOLS_CHECK_OVERFLOW__
*/
2020-04-24 11:30:09 +02:00
#define __XTOOLS_CHECK_OVERFLOW__
2020-04-24 11:30:09 +02:00
#define Xrealloc(ptr, newsize, oldsize) realloc(ptr, newsize)
2020-03-26 13:59:20 +01:00
#include <posix/posix.h>
2021-03-15 10:02:34 +01:00
#define XTOOLS_VA_LIST va_list
#define XTOOLS_VA_START va_start
#define XTOOLS_VA_END va_end
#define XTOOLS_VA_ARG va_arg
2021-03-15 10:02:34 +01:00
#endif