Re: INT64_MIN and _MAX - Mailing list pgsql-hackers

From Andrew Gierth
Subject Re: INT64_MIN and _MAX
Date
Msg-id 87egoe6r0z.fsf@news-spur.riddles.org.uk
Whole thread Raw
In response to Re: INT64_MIN and _MAX  (Andres Freund <andres@anarazel.de>)
Responses Re: INT64_MIN and _MAX  (Kevin Grittner <kgrittn@ymail.com>)
List pgsql-hackers
>>>>> "Andres" == Andres Freund <andres@anarazel.de> writes:
>> This replaces the one I posted before; it does both INT64_MIN/MAX and>> INT32_MIN/MAX, and also int16/int8/uint*.
Usesof 0x7fffffff in code>> have been replaced unless there was a reason not to, with either INT_MAX>> or INT32_MAX
accordingto the type required.
 
Andres> Any reason you did that for most of 0x7FFFFFFF, but not for theAndres> corresponding 0xFFFFFFFF/unsigned case?
I'dlike to eitherAndres> avoid going around changing other definitions, or do a somewhatAndres> systematic job.
 

I didn't replace the 0xFFFFFFFF ones because most or all of them looked
like basically bit-masking operations rather than actually dealing with
the bounds of an unsigned int or uint32.  I was specifically looking for
places where literals were being used to represent maximum or minimum
values.

-- 
Andrew (irc:RhodiumToad)



pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Re: Replication identifiers, take 4
Next
From: Tom Lane
Date:
Subject: Re: Exposing PG_VERSION_NUM in pg_config