dictionary: Always compact immediately upon deletion of a variable.
authorBen Pfaff <blp@cs.stanford.edu>
Sun, 5 Mar 2023 03:06:12 +0000 (19:06 -0800)
committerBen Pfaff <blp@cs.stanford.edu>
Sun, 5 Mar 2023 19:23:16 +0000 (11:23 -0800)
commit1dcdba517fbb5c99c37e0a03275325f256975c7c
tree0b7c775d53f3821ff91b4caf0fee2f7fe564a33f
parentafea472df1680beefe6d2b693f3c954fde3b3313
dictionary: Always compact immediately upon deletion of a variable.

With this change, the dictionary has a new invariant that the case_indexes
are always a permutation of [0,N) where N is the number of variables in
the dictionary.  Most commonly, the case_indexes are the same as the
dict_indexes, but reordering the dictionary can permute them.
19 files changed:
src/data/case-map.c
src/data/case-map.h
src/data/dataset-writer.c
src/data/dataset.c
src/data/datasheet.c
src/data/dictionary.c
src/data/dictionary.h
src/data/pc+-file-reader.c
src/data/sys-file-reader.c
src/language/commands/combine-files.c
src/language/commands/get.c
src/language/commands/save-translate.c
src/language/commands/save.c
src/ui/gui/marshaller-list
src/ui/gui/psppire-data-store.c
src/ui/gui/psppire-data-store.h
src/ui/gui/psppire-data-window.c
src/ui/gui/psppire-dict.c
utilities/pspp-convert.c