Subject: Re: bug#34951: [PATCH] grep: a kwset matcher not work in a grep matcher

From: [email-masked]
Date: Fri, 13 Dec 2019 01:09:56 -0700

Hi Paul.

Paul Eggert <[email-masked]> wrote:

> On 12/11/19 11:31 PM, [email-masked] wrote:
>
> > 	1,$s/ptrdiff_t/ssize_t/g
>
> ssize_t can be narrower than ptrdiff_t, so it's not a good type to use 
> for this notion. Its original motivation was "the type that 'read' 
> returns", and on systems where 'read' can return at most INT_MAX, 
> ssize_t can be 32 bits even if size_t is 64 bits.

In practice, how many system are there where ssize_t is 32 bits and size_t
is 64? If that number is <= 5 then I wouldn't worry about using ssize_t.

In any case, as I said, I can live with ptrdiff_t in the implementation,
even though I don't like it that much.  (A nice block comment at the
top of dfa.c explaining why ptrdiff_t is used would be appropriate.)

But I really don't want ptrdiff_t in the API.

Thanks,

Arnold

Thanks,

Arnold