[PATCH] quiet conversion warning in DatumGetFloat4
Chapman Flack <chap@anastigmatix.net>
From: Chapman Flack <chap@anastigmatix.net>
To: PostgreSQL Hackers <pgsql-hackers@postgresql.org>
Date: 2017-05-31T04:56:36Z
Lists: pgsql-hackers
Attachments
- quiet-conversion-warning-getfloat4.patch (text/x-patch) patch
It seems that 14cca1b (use static inline functions for float <-> Datum conversions) has an implicit narrowing conversion in one of those functions. If building an extension with gcc's -Wconversion warning enabled (*cough* pljava *cough* ... the Maven plugin that runs the compiler enables the warning by default), this makes for a noisy build. The warning is harmless, but repeated everywhere postgres.h is included. An explicit cast is enough to suppress it. -Chap
Commits
-
Avoid -Wconversion warnings from direct use of GET_n_BYTES macros.
- b5b322914100 10.0 landed