From: Junio C Hamano Date: Wed, 24 Sep 2025 17:29:12 GMT Subject: Re: [PATCH v5 12/13] xdiff: use enum macros NONE(0), SOME(1), TOO_MANY(2) in xprepare.c Message-ID: In-Reply-To: <1c3461c3-09bb-404d-a4dc-a895baba68f2@gmail.com> Phillip Wood writes: > Our coding guidelines say not to use "!!x" (I assume we're supposed to > do "x != 0" instead) but in practice it's pretty common to see it in > our codebase. I'd maybe try a (bool) cast and see what people say. Offtopic. I am perfectly fine to remove the "avoid !!x, as it is too clever and confusing to others" entry from the guidelines. As we have many of them and it is a fairly well understood idiom in C, I would imagine that it have become less confusing already since the entry was written. > Thanks for cleaning up the xdiff code, it is much appreciated Hear, hear.