[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20160307022414.GA6259@thunk.org>
Date: Sun, 6 Mar 2016 21:24:14 -0500
From: Theodore Ts'o <tytso@....edu>
To: Andreas Dilger <adilger@...ger.ca>
Cc: linux-ext4@...r.kernel.org
Subject: Re: misc: replace comparison macros with inline functions
On Sat, Mar 05, 2016 at 05:30:16PM -0700, Andreas Dilger wrote:
> Replace the EXT2FS_RB_EMPTY_ROOT(), EXT2FS_RB_EMPTY_NODE(),
> EXT2FS_RB_CLEAR_NODE(), IS_BLOCK_BM(), IS_INODE_BM(), and
> IS_INODE_TB() macros with static inline functions to avoid
> suprious compiler warnings with clang:
>
> pass1.c:618:28: warning: equality comparison with extraneous
> parentheses [-Wparentheses-equality]
> if ((*((__u32 *)(entry)) == 0UL)) {
> ~~~~~~~~~~~~~~~~~~~~^~~~~~
> pass1.c:618:28: note: remove extraneous parentheses
> around the comparison to silence this warning
> if ((*((__u32 *)(entry)) == 0UL)) {
> ^~
> pass1.c:618:28: note: use '=' to turn this equality
> comparison into an assignment
> if ((*((__u32 *)(entry)) == 0UL)) {
> ^~
> =
>
> The static inline functions should compile identically, and allow
> some extra compile-time checking for the arguments over macros.
>
> Signed-off-by: Andreas Dilger <adilger@...ger.ca>
Thanks, applied.
- Ted
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists