Re: [PATCH v2 2/3] diff: add -I<regex> that ignores matching changes
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Oct 12, 2020, 20:04 UTC
- Message-ID
- <xmqqk0vvnrcb.fsf@gitster.c.googlers.com>
- In-Reply-To
- <20201012091751.19594-3-michal@isc.org>
Michał Kępień <michal@isc.org> writes:
> + /* see Documentation/diff-options.txt */
This comment adds negative value.
If it were
/* "-I<regexp>" */
the readers won't have to switch to the file only to find out that the comment didn't tell them where in the file to look at.
Show 15 quoted lines
> + regex_t **ignore_regex;
> + size_t ignore_regex_nr, ignore_regex_alloc;
> +
> const char *single_follow;
> const char *a_prefix, *b_prefix;
> const char *line_prefix;
> diff --git a/xdiff/xdiff.h b/xdiff/xdiff.h
> index 032e3a9f41..883a0d770e 100644
> --- a/xdiff/xdiff.h
> +++ b/xdiff/xdiff.h
> @@ -79,6 +79,10 @@ typedef struct s_mmbuffer {
> typedef struct s_xpparam {
> unsigned long flags;
>
> + /* See Documentation/diff-options.txt. */Likewise.
Show 6 quoted lines
> + regex_t **ignore_regex; > + size_t ignore_regex_nr; > + > /* See Documentation/diff-options.txt. */ > char **anchors; > size_t anchors_nr;