lkml.org 
[lkml]   [2019]   [Apr]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] Staging: rtlwifi: Remove unwanted parentheses
On Wed, Apr 03, 2019 at 07:21:45PM +0300, Dan Carpenter wrote:
> On Wed, Apr 03, 2019 at 07:18:03PM +0300, Dan Carpenter wrote:
> > data_bit = (data & BIT(i)) ? 1 : 0;
>
> I quite like the !! idiom also...
>
> data_bit = !!(data & BIT(i));

Thanks for reviewing it.

>
> regards,
> dan carpenter

\
 
 \ /
  Last update: 2019-04-04 00:52    [W:0.070 / U:0.188 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site