postgresql/src
Peter Eisentraut e5f1bb92cf Simplify index tuple descriptor initialization
We have two code paths for initializing the tuple descriptor for a new
index: For a normal index, we copy the tuple descriptor from the table
and reset a number of fields that are not applicable to indexes.  For an
expression index, we make a blank tuple descriptor and fill in the
needed fields based on the provided expressions.  As pg_attribute has
grown over time, the number of fields that we need to reset in the first
case is now bigger than the number of fields we actually want to copy,
so it's sensible to do it the other way around: Make a blank descriptor
and copy just the fields we need.  This also allows more code sharing
between the two branches, and it avoids having to touch this code for
almost every unrelated change to the pg_attribute structure.

Reviewed-by: Arthur Zakirov <a.zakirov@postgrespro.ru>
2018-09-13 08:22:03 +02:00
..
backend Simplify index tuple descriptor initialization 2018-09-13 08:22:03 +02:00
bin Minor fixes for psql tab completion. 2018-09-12 15:25:12 -04:00
common Install a check for mis-linking of src/port and src/common functions. 2018-09-09 12:23:23 -04:00
fe_utils Fix lexing of standard multi-character operators in edge cases. 2018-08-23 21:42:40 +01:00
include Hide a static inline from FRONTEND code. 2018-09-10 12:47:02 -04:00
interfaces ecpg: Change --version output to common style 2018-09-12 14:33:15 +02:00
makefiles Refactor installation of extension headers. 2018-09-07 14:19:14 +01:00
pl Use C99 designated initializers for some structs 2018-09-07 11:40:03 +02:00
port Fix inconsistent argument naming. 2018-09-06 11:14:22 -04:00
template Force "restrict" not to be used when compiling with xlc. 2017-10-13 12:15:06 -07:00
test Repair bug in regexp split performance improvements. 2018-09-12 19:31:06 +01:00
timezone Update time zone data files to tzdata release 2018e. 2018-05-09 13:56:22 -04:00
tools Install a check for mis-linking of src/port and src/common functions. 2018-09-09 12:23:23 -04:00
tutorial Deduplicate "invalid input syntax" messages for various types. 2018-07-22 14:58:01 -07:00
.gitignore
DEVELOPERS
Makefile Fix partial-build problems introduced by having more generated headers. 2018-04-09 16:42:10 -04:00
Makefile.global.in Ensure we build generated headers at the start of some more cases. 2018-07-30 18:04:39 -04:00
Makefile.shlib Use -Bsymbolic for shared libraries on HP-UX and Solaris. 2018-09-10 22:22:12 -04:00
nls-global.mk nls-global.mk: search build dir for source files, too 2016-06-07 18:55:18 -04:00