0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-12-29 08:54:02 +01:00

librb: Move bool type stuff from ircd stdinc to rb.

This commit is contained in:
Jason Volk 2016-06-27 15:21:23 -07:00
parent 1490dd36b5
commit c5698b0276
2 changed files with 18 additions and 17 deletions

View file

@ -70,23 +70,6 @@ char *alloca ();
#endif #endif
#ifdef HAVE_STDBOOL_H
# include <stdbool.h>
#else
# ifndef HAVE__BOOL
# ifdef __cplusplus
typedef bool _Bool;
# else
# define _Bool signed char
# endif
# endif
# define bool _Bool
# define false 0
# define true 1
# define __bool_true_false_are_defined 1
#endif
#include <stdio.h> #include <stdio.h>
#include <assert.h> #include <assert.h>
#include <stdio.h> #include <stdio.h>

View file

@ -10,6 +10,24 @@
#include <signal.h> #include <signal.h>
#include <ctype.h> #include <ctype.h>
#ifdef HAVE_STDBOOL_H
#include <stdbool.h>
#else
#ifndef HAVE__BOOL
#ifdef __cplusplus
typedef bool _Bool;
#else
#define _Bool signed char
#endif
#endif
#define bool _Bool
#define false 0
#define true 1
#define __bool_true_false_are_defined 1
#endif
#ifdef __GNUC__ #ifdef __GNUC__
#undef alloca #undef alloca
#define alloca __builtin_alloca #define alloca __builtin_alloca