From 2939b749b1169a0c01c19698a3f0026034346ebd Mon Sep 17 00:00:00 2001 From: Kimplul Date: Mon, 30 Aug 2021 16:40:48 +0300 Subject: Initial formatted debug output + Mostly follows the POSIX printf, with the exceptions of no floating points and `X` signifies binary instead of uppercase hex --- include/apos/bits.h | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 include/apos/bits.h (limited to 'include/apos/bits.h') diff --git a/include/apos/bits.h b/include/apos/bits.h new file mode 100644 index 0000000..77bdde4 --- /dev/null +++ b/include/apos/bits.h @@ -0,0 +1,8 @@ +#ifndef APOS_BITS_H +#define APOS_BITS_H + +#define __is_set(x, y) ((x) & (y)) +#define __set_bit(x, y) ((x) |= (y)) +#define __clear_bit(x, y) ((x) &= ~(y)) + +#endif /* APOS_BITS_H */ -- cgit v1.3