From acab97ae087cd5a082968537c10974361e95234e Mon Sep 17 00:00:00 2001 From: Stephen Heumann Date: Mon, 25 Jan 2021 22:04:26 -0600 Subject: [PATCH] Add header. Also, revise handling of boolean constants in so that they do not conflict with the definitions in . --- ORCACDefs/stdbool.h | 15 +++++++++++++++ ORCACDefs/types.h | 12 ++++++++++-- 2 files changed, 25 insertions(+), 2 deletions(-) create mode 100644 ORCACDefs/stdbool.h diff --git a/ORCACDefs/stdbool.h b/ORCACDefs/stdbool.h new file mode 100644 index 0000000..af56af4 --- /dev/null +++ b/ORCACDefs/stdbool.h @@ -0,0 +1,15 @@ +/**************************************************************** +* +* stdbool.h - boolean type and values +* +****************************************************************/ + +#ifndef __stdbool__ +#define __stdbool__ + +#define bool _Bool +#define true 1 +#define false 0 +#define __bool_true_false_are_defined 1 + +#endif diff --git a/ORCACDefs/types.h b/ORCACDefs/types.h index 727f14f..386afc9 100644 --- a/ORCACDefs/types.h +++ b/ORCACDefs/types.h @@ -27,10 +27,18 @@ #define dispatcher 0xE10000L /* tool locator dispatch address */ +#ifndef TRUE #define TRUE 1 -#define true TRUE +#endif +#ifndef true +#define true 1 +#endif +#ifndef FALSE #define FALSE 0 -#define false FALSE +#endif +#ifndef false +#define false 0 +#endif /* RefDescriptors */ #define refIsPointer 0x0000