Re: Postgres storing time in strange manner - Mailing list pgsql-bugs

From Peter Eisentraut
Subject Re: Postgres storing time in strange manner
Date
Msg-id Pine.LNX.4.44.0209170049420.1307-100000@localhost.localdomain
Whole thread Raw
In response to Re: Postgres storing time in strange manner  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Postgres storing time in strange manner
List pgsql-bugs
Tom Lane writes:

> Not sure; apparently it depends on optimization level, so I'd be
> hesitant to assume that any short test case would reliably expose
> the problem.  Also, aren't you trying to avoid run-time tests in
> configure?

If the test doesn't use any library function's run-time behavior, you can
usually do something like

main() {
int a[(2.0+2.0==4.0)?1:-1]
}

This will fail to compile if the floating-point arithmetic is broken.

Otherwise a good solution might be to print a warning if configure detects
the flag.  Or we can strip it out unconditionally, but that seems wrong.
The user should be made aware of the problem.

--
Peter Eisentraut   peter_e@gmx.net

pgsql-bugs by date:

Previous
From: Neil Conway
Date:
Subject: Re: Bug #770: 7.2.1 --> 7.2.2 =? Problems with speed
Next
From: Neil Conway
Date:
Subject: Re: Bug #758: show_planner_stats does not work for new PREPARE calls