postgresql/contrib/btree_gin
Tom Lane 41c912cad1 Clean up warnings from -Wimplicit-fallthrough.
Recent gcc can warn about switch-case fall throughs that are not
explicitly labeled as intentional.  This seems like a good thing,
so clean up the warnings exposed thereby by labeling all such
cases with comments that gcc will recognize.

In files that already had one or more suitable comments, I generally
matched the existing style of those.  Otherwise I went with
/* FALLTHROUGH */, which is one of the spellings approved at the
more-restrictive-than-default level -Wimplicit-fallthrough=4.
(At the default level you can also spell it /* FALL ?THRU */,
and it's not picky about case.  What you can't do is include
additional text in the same comment, so some existing comments
containing versions of this aren't good enough.)

Testing with gcc 8.0.1 (Fedora 28's current version), I found that
I also had to put explicit "break"s after elog(ERROR) or ereport(ERROR);
apparently, for this purpose gcc doesn't recognize that those don't
return.  That seems like possibly a gcc bug, but it's fine because
in most places we did that anyway; so this amounts to a visit from the
style police.

Discussion: https://postgr.es/m/15083.1525207729@sss.pgh.pa.us
2018-05-01 19:35:08 -04:00
..
expected Add support of bool, bpchar, name and uuid to btree_gin 2018-04-05 18:19:10 +03:00
sql Add support of bool, bpchar, name and uuid to btree_gin 2018-04-05 18:19:10 +03:00
.gitignore
btree_gin--1.0--1.1.sql Add support for EUI-64 MAC addresses as macaddr8 2017-03-15 11:16:25 -04:00
btree_gin--1.0.sql
btree_gin--1.1--1.2.sql Add btree_gin support for enum types 2017-03-21 11:04:17 -04:00
btree_gin--1.2--1.3.sql Add support of bool, bpchar, name and uuid to btree_gin 2018-04-05 18:19:10 +03:00
btree_gin--unpackaged--1.0.sql
btree_gin.c Clean up warnings from -Wimplicit-fallthrough. 2018-05-01 19:35:08 -04:00
btree_gin.control Add support of bool, bpchar, name and uuid to btree_gin 2018-04-05 18:19:10 +03:00
Makefile Add support of bool, bpchar, name and uuid to btree_gin 2018-04-05 18:19:10 +03:00