forked from github/server
boolean für GCC-sauerei
This commit is contained in:
parent
89d0e42ef3
commit
b23e653e47
24
src/config.h
24
src/config.h
|
@ -24,14 +24,6 @@
|
|||
|
||||
|
||||
|
||||
/**** ****
|
||||
** The Eressea boolean type **
|
||||
**** ****/
|
||||
|
||||
typedef int boolean;
|
||||
#define false ((boolean)0)
|
||||
#define true ((boolean)!false)
|
||||
|
||||
|
||||
|
||||
/**** ****
|
||||
|
@ -57,6 +49,12 @@ typedef int boolean;
|
|||
# include <dmalloc.h>
|
||||
#endif
|
||||
|
||||
#if defined(__GCC__)
|
||||
# include <stdbool.h>
|
||||
# define HAS_BOOLEAN
|
||||
# define boolean bool
|
||||
#endif
|
||||
|
||||
#if defined(_DEBUG) && defined(_MSC_VER)
|
||||
# ifndef MALLOCDBG
|
||||
# define MALLOCDBG 1
|
||||
|
@ -232,4 +230,14 @@ extern char * strdup(const char *s);
|
|||
|
||||
#define unused(var) var = var
|
||||
|
||||
|
||||
/**** ****
|
||||
** The Eressea boolean type **
|
||||
**** ****/
|
||||
#ifndef HAS_BOOLEAN
|
||||
typedef int boolean;
|
||||
# define false ((boolean)0)
|
||||
# define true ((boolean)!false)
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue