Re: A bug when use get_bit() function for a long bytea string - Mailing list pgsql-hackers

From Tom Lane
Subject Re: A bug when use get_bit() function for a long bytea string
Date
Msg-id 11357.1585231718@sss.pgh.pa.us
Whole thread Raw
In response to Re: A bug when use get_bit() function for a long bytea string  (Ashutosh Bapat <ashutosh.bapat@2ndquadrant.com>)
Responses Re: A bug when use get_bit() function for a long bytea string  (Ashutosh Bapat <ashutosh.bapat@2ndquadrant.com>)
List pgsql-hackers
Ashutosh Bapat <ashutosh.bapat@2ndquadrant.com> writes:
> On Wed, 18 Mar 2020 at 08:18, movead.li@highgo.ca <movead.li@highgo.ca>
> wrote:
>> if we change return type of all those functions to int64, we won't need
>> this cast.
>> I change the 'encode' function, it needs an int64 return type, but keep
>> other
>> functions in 'pg_encoding', because I think it of no necessary reason.

> Ok, let's leave it for a committer to decide.

If I'm grasping the purpose of these correctly, wouldn't Size or size_t
be a more appropriate type?  And I definitely agree with changing all
of these APIs at once, if they're all dealing with the same kind of
value.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Magnus Hagander
Date:
Subject: Re: pg_checksums in backend/storage/page/README
Next
From: Julien Rouhaud
Date:
Subject: Re: pg_checksums in backend/storage/page/README