commit 31c504d43263a891b7a9d37517f9e26fb650d20b
Author: Oswald Buddenhagen <[email protected]>
Date: Mon Jul 24 11:34:10 2023 +0200
remove redundant argument from BIT_FORMATTER_PROTO()
it doesn't need to know the enum prefix.
amends 17db5de0c & 950ebe833.
src/common.h | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/src/common.h b/src/common.h
index 940e74d..9c44bce 100644
--- a/src/common.h
+++ b/src/common.h
@@ -212,12 +212,12 @@ void fmt_bits( uint bits, uint num_bits, const char
*bit_str, const int *bit_off
#define BIT_FORMATTER_RET(name, pfx) \
struct name##_str { char str[sizeof(pfx##__STRINGS)]; };
-#define BIT_FORMATTER_PROTO(name, pfx, storage) \
+#define BIT_FORMATTER_PROTO(name, storage) \
storage struct name##_str ATTR_OPTIMIZE /* force RVO */ \
fmt_##name( uint bits )
#define BIT_FORMATTER_IMPL(name, pfx, storage) \
- BIT_FORMATTER_PROTO(name, pfx, storage) \
+ BIT_FORMATTER_PROTO(name, storage) \
{ \
static const char strings[] = pfx##__STRINGS; \
static const int offsets[] = { pfx##__OFFSETS }; \
@@ -233,7 +233,7 @@ void fmt_bits( uint bits, uint num_bits, const char
*bit_str, const int *bit_off
#define DECL_BIT_FORMATTER_FUNCTION(name, pfx) \
BIT_FORMATTER_RET(name, pfx) \
- BIT_FORMATTER_PROTO(name, pfx, );
+ BIT_FORMATTER_PROTO(name, );
#define DEF_BIT_FORMATTER_FUNCTION(name, pfx) \
BIT_FORMATTER_IMPL(name, pfx, )
_______________________________________________
isync-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/isync-devel