[prev in list] [next in list] [prev in thread] [next in thread]
List: git
Subject: Re: janitoring
From: Johannes Sixt <j.sixt () viscovery ! net>
Date: 2009-07-23 7:27:42
Message-ID: 4A6810EE.4030902 () viscovery ! net
[Download RAW message or body]
Pierre Habouzit schrieb:
> [PATCH 2/3] refactor: use bitsizeof() instead of 8 * sizeof()
>
> use a macro for CHAR_BIT * sizeof(...), I tend to find it more
> readable than 8 * sizeof(...) in the code. YMMV.
>
> [PATCH 3/3] janitor: add DIV_ROUND_UP and use it.
>
> Just use linux/kernel.h DIV_ROUND_UP(a, b), it's way easier to read
> than (a + b - 1) / (b).
Quite frankly, using these two macros means that code readers have to
learn their meaning although the original code pieces are (IMO) well-known
paradigms. Moreover, DIV_ROUND_UP hides that b is evaluated twice. I am
not enthused by these patches (though, I don't see a reason to object).
-- Hannes
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic