pgsql: Better fix for determining minimum and maximum int64 values that

Started by Nonamealmost 19 years ago3 messages
#1Noname
petere@postgresql.org

Log Message:
-----------
Better fix for determining minimum and maximum int64 values that doesn't
require stdint.h and works for "busted" int64.

Modified Files:
--------------
pgsql/src/backend/utils/adt:
xml.c (r1.30 -> r1.31)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/xml.c.diff?r1=1.30&r2=1.31)

#2Alvaro Herrera
alvherre@commandprompt.com
In reply to: Noname (#1)
Re: pgsql: Better fix for determining minimum and maximum int64 values that

Peter Eisentraut wrote:

Log Message:
-----------
Better fix for determining minimum and maximum int64 values that doesn't
require stdint.h and works for "busted" int64.

Nice trick -- is this worth being in c.h or thereabouts?

--
Alvaro Herrera http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.

#3Peter Eisentraut
peter_e@gmx.net
In reply to: Alvaro Herrera (#2)
Re: pgsql: Better fix for determining minimum and maximum int64 values that

Alvaro Herrera wrote:

Peter Eisentraut wrote:

Log Message:
-----------
Better fix for determining minimum and maximum int64 values that
doesn't require stdint.h and works for "busted" int64.

Nice trick -- is this worth being in c.h or thereabouts?

I was thinking about adding something like PG_INT64_MAX etc. to c.h, but
that might have required adding limit.h to c.h and perhaps other
rearrangements, and that would have gone too far for the moment. If
more call sites use it, it should be refactored.

--
Peter Eisentraut
http://developer.postgresql.org/~petere/