Drop the per-entry copy of the flag mode in CompoundAffixFlags. Each CompoundAffixFlag carried its own copy of the dictionary's flag mode, which decides whether the union holds a string or an integer. The comment on the field explained why: cmpcmdflag() needs the mode, and at the time there was no bsearch() variant that would allow passing that context through. But that problem is long gone, so let's remove the redundant storage. No flexibility is lost because things would not work anyway if different flags within a dictionary have different representations; and the preceding commit has seen to it that they can't. At present, this saves no storage on 64-bit machines because of alignment issues, but it still seems like good simplification.
No back-patch: there's little value in this except cleanliness, and although probably no outside code is looking at this data structure, this'd be an API/ABI break if any does. Author: Ewan Young <[email protected]> Reviewed-by: Tom Lane <[email protected]> Discussion: https://postgr.es/m/CAON2xHN3QmsaySM6DGWa1gttcbJoFh0wjAE-_ZpSPo=lkn1...@mail.gmail.com Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/2fb8da5a245661287833b05a1b2e275ddf83bbd7 Modified Files -------------- src/backend/tsearch/spell.c | 22 +++++++++------------- src/include/tsearch/dicts/spell.h | 6 ++---- 2 files changed, 11 insertions(+), 17 deletions(-)
