Re: [PATCH] dir: check for single file cone patterns
- From
Ævar Arnfjörð Bjarmason <avarab@gmail.com>
- Date
- Dec 20, 2022, 14:33 UTC
- Message-ID
- <221220.86sfhaw3c3.gmgdl@evledraar.gmail.com>
- In-Reply-To
- <pull.1446.git.1671546459151.gitgitgadget@gmail.com>
On Tue, Dec 20 2022, William Sprent via GitGitGadget wrote:
> From: William Sprent <williams@unity3d.com>
> [...]
> + if (!(given->flags & PATTERN_FLAG_MUSTBEDIR) &&
> + !!strcmp(given->pattern, "/*")) {Style: We use !! to convert 123 to 1 or whatever, but here we just care about "not matched", so we can drop this !!strcmp() for strcmp().