Re: BUG #12885: The result of casting a double to an integer depends on the database version

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: BUG #12885: The result of casting a double to an integer depends on the database version
Дата
Msg-id 26862.1427166720@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: BUG #12885: The result of casting a double to an integer depends on the database version  (Michael Paquier <michael.paquier@gmail.com>)
Ответы Re: BUG #12885: The result of casting a double to an integer depends on the database version  (Michael Paquier <michael.paquier@gmail.com>)
Список pgsql-bugs
Michael Paquier <michael.paquier@gmail.com> writes:
> On Tue, Mar 24, 2015 at 11:27 AM, Michael Paquier wrote:
>> On a Windows 7 box with code compiled with MSVC 2010 I am seeing the
>> same behavior as Rich. This looks like a bug in ~9.3 that meritates
>> some attention assuming that the latter behavior is legit.

> And MinGW outputs the latter, similarly to other platforms... I'll investigate.

Look for something about setting the IEEE float rounding mode.  "Round to
nearest even" is standard in most places, but it would not astonish me
to hear that Microsoft got that wrong.

If it is wrong I don't know that we'd want to back-patch a behavioral
change, but I'd definitely vote for conforming to the norm in 9.5
and later.

            regards, tom lane

В списке pgsql-bugs по дате отправления:

Предыдущее
От: Michael Paquier
Дата:
Сообщение: Re: BUG #12885: The result of casting a double to an integer depends on the database version
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: BUG #12885: The result of casting a double to an integer depends on the database version