lkml.org 
[lkml]   [2018]   [Sep]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] rsxx: Remove unnecessary parentheses
From
Date
On 9/11/18 3:50 PM, Nathan Chancellor wrote:
> Clang warns when more than one set of parentheses is used for a
> single conditional statement:
>
> drivers/block/rsxx/cregs.c:279:15: warning: equality comparison with
> extraneous parentheses [-Wparentheses-equality]
> if ((cmd->op == CREG_OP_READ)) {
> ~~~~~~~~^~~~~~~~~~~~~~~
> drivers/block/rsxx/cregs.c:279:15: note: remove extraneous parentheses
> around the comparison to silence this warning
> if ((cmd->op == CREG_OP_READ)) {
> ~ ^ ~
> drivers/block/rsxx/cregs.c:279:15: note: use '=' to turn this equality
> comparison into an assignment
> if ((cmd->op == CREG_OP_READ)) {
> ^~
> =
> 1 warning generated.

Applied for 4.20, thanks.

--
Jens Axboe

\
 
 \ /
  Last update: 2018-09-12 00:57    [W:0.029 / U:0.384 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site