[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <111c5853-e488-0aaa-18e9-36792b648427@ionic.de>
Date: Sat, 27 Mar 2021 23:12:08 +0100
From: Mihai Moldovan <ionic@...ic.de>
To: Randy Dunlap <rdunlap@...radead.org>,
Masahiro Yamada <masahiroy@...nel.org>
Cc: linux-kernel@...r.kernel.org
Subject: Re: [PATCH] kconfig: nconf: stop endless search-up loops
* On 3/27/21 4:58 PM, Randy Dunlap wrote:
> On 3/27/21 5:01 AM, Mihai Moldovan wrote:
>> + if ((-1 == index) && (index == match_start))
>
> checkpatch doesn't complain about this (and I wonder how it's missed), but
> kernel style is (mostly) "constant goes on right hand side of comparison",
> so
> if ((index == -1) &&
I can naturally send a V2 with that swapped.
To my rationale: I made sure to use checkpatch, saw that it was accepted and
even went for a quick git grep -- '-1 ==', which likewise returned enough
results for me to call this consistent with the current code style.
Maybe those matches were just frowned-upon, but forgotten-to-be-critized
examples of this pattern being used.
Mihai
Download attachment "OpenPGP_signature" of type "application/pgp-signature" (841 bytes)
Powered by blists - more mailing lists