From 1f26a4fcbb0e242873dcde21f2e3601390096a0e Mon Sep 17 00:00:00 2001 From: Bruno Raoult Date: Wed, 10 Nov 2021 10:26:44 +0100 Subject: [PATCH] Update 'foo.h' --- foo.h | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) diff --git a/foo.h b/foo.h index 80cbc0f..f8a94c1 100644 --- a/foo.h +++ b/foo.h @@ -1,19 +1,3 @@ -/** bit_for_each64 - iterate over an u64 bits - * @pos: an int used as current bit - * @tmp: a temp u64 used as temporary storage - * @ul: the u64 to loop over - * - * Usage: - * u64 u=139, _t; // u=b10001011 - * int cur; - * bit_for_each64(cur, _t, u) { - * printf("%d\n", cur); - * } - * This will display the position of each bit in u: 1, 2, 4, 8 - * - * I should probably re-think the implementation... - */ +/**/ #define bit_for_each64(pos, tmp, ul) \ for (tmp = ul, pos = ffs64(tmp); pos; tmp &= (tmp - 1), pos = ffs64(tmp)) - -#endif /* BITS_H */