Fix statically allocated struct with FLEXIBLE_ARRAY_MEMBER member.
authorTom Lane <tgl@sss.pgh.pa.us>
Fri, 20 Feb 2015 22:50:18 +0000 (17:50 -0500)
committerTom Lane <tgl@sss.pgh.pa.us>
Fri, 20 Feb 2015 22:50:18 +0000 (17:50 -0500)
commit33b2a2c97f3dd4cf8bbc2c020e34129886367b72
tree56580daeff63dca5ea7979769c33d6e9994b59c5
parent33a3b03d636b529b27f869e332b6344d52635331
Fix statically allocated struct with FLEXIBLE_ARRAY_MEMBER member.

clang complains about this, not unreasonably, so define another struct
that's explicitly for a WordEntryPos with exactly one element.

While at it, get rid of pretty dubious use of a static variable for
more than one purpose --- if it were being treated as const maybe
I'd be okay with this, but it isn't.
src/backend/utils/adt/tsrank.c
src/include/tsearch/ts_type.h