From e78b0f7c9ea25ffb967ad9737f3e040049c969ff Mon Sep 17 00:00:00 2001 From: Per Hedbor <ph@opera.com> Date: Tue, 25 Feb 2014 15:24:08 +0100 Subject: [PATCH] BITN was removed from the bitvector.h file This was done in 44b036909ceca9055d8e591b91ba6bfceb80ee68. To compile again, re-add it here (for now at least) --- src/post_modules/CritBit/critbit/critbit.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/post_modules/CritBit/critbit/critbit.h b/src/post_modules/CritBit/critbit/critbit.h index 29b29be29b..489bd2ea68 100644 --- a/src/post_modules/CritBit/critbit/critbit.h +++ b/src/post_modules/CritBit/critbit/critbit.h @@ -15,6 +15,11 @@ #define CB_TYPE(name) CONCAT5(cb_, CB_NAMESPACE, _, name, _t) #endif + +#define MASK(type, bits) (~((~((type)0)) >> (bits))) +#define BITMASK(type, n) ((type)1 << (type)(sizeof(type)*8 - 1 - (n))) +#define BITN(type, p, n) (!!((p) & BITMASK(type, n))) + typedef struct cb_size { size_t bits; ptrdiff_t chars; -- GitLab