On 2015-07-17 21:40:45 +0300, Heikki Linnakangas wrote: > Hmm, that function is pretty fragile, it will segfault on any AT_* type that > it doesn't recognize. Thankfully you get that compiler warning, but we have > added AT_* type codes before in minor releases.
For in-core code that is supposed to handle all cases I find it much better to get a compiler warning than to error out in a default: case. The latter is very likely not going to be exercised by any test and thus not be noticed for prolonged time. Might make sense to test for -Werror=switch and add that to the compiler flags by default. Andres -- Sent via pgsql-hackers mailing list (firstname.lastname@example.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers