Re: [HACKERS] taking stdbool.h into use
От | Peter Eisentraut |
---|---|
Тема | Re: [HACKERS] taking stdbool.h into use |
Дата | |
Msg-id | b4bb1f5d-027f-63c7-5eed-9b1cd2cfaa46@2ndquadrant.com обсуждение исходный текст |
Ответ на | Re: [HACKERS] taking stdbool.h into use (Peter Eisentraut <peter.eisentraut@2ndquadrant.com>) |
Список | pgsql-hackers |
On 1/11/18 17:01, Peter Eisentraut wrote: > Looking around where else they are used, the uses in numeric.c sure seem > like noops: > > #if SIZEOF_DATUM == 8 > #define NumericAbbrevGetDatum(X) ((Datum) SET_8_BYTES(X)) > #define DatumGetNumericAbbrev(X) ((int64) GET_8_BYTES(X)) > #define NUMERIC_ABBREV_NAN NumericAbbrevGetDatum(PG_INT64_MIN) > #else > #define NumericAbbrevGetDatum(X) ((Datum) SET_4_BYTES(X)) > #define DatumGetNumericAbbrev(X) ((int32) GET_4_BYTES(X)) > #define NUMERIC_ABBREV_NAN NumericAbbrevGetDatum(PG_INT32_MIN) > #endif > > We can just replace these by straight casts, too. I have committed a change for this. I'll work through the other details later. -- Peter Eisentraut http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
В списке pgsql-hackers по дате отправления: