aboutsummaryrefslogtreecommitdiff
path: root/src/include/bootstrap/bootstrap.h
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2018-04-17 18:29:11 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2018-04-17 18:29:11 -0400
commit9ffcccdb958d38db5051bf64143330ff445a26cc (patch)
treed1d6cac61239dca001ceb56afa086af5bb8e8849 /src/include/bootstrap/bootstrap.h
parente90d4ddc639aac7a7217ebc670ad6e49eaeddbf9 (diff)
downloadpostgresql-9ffcccdb958d38db5051bf64143330ff445a26cc.tar.gz
postgresql-9ffcccdb958d38db5051bf64143330ff445a26cc.zip
Rationalize handling of array type names in bootstrap data.
Formerly, Catalog.pm turned a C array type declaration in the catalog header files into a SQL type, e.g., 'foo[]'. Along the way, genbki.pl turned this into '_foo' for the purpose of type lookups, but wrote 'foo[]' to postgres.bki. During bootstrap, bootscanner.l had to have a special case rule to tokenize this, and then MapArrayTypeName() would turn 'foo[]' into '_foo' one more time. This seems unnecessarily complicated, especially since nobody cares that much about the readability of postgres.bki. Instead, make Catalog.pm convert the C declaration into '_foo' to start with, and preserve that representation of the type name throughout bootstrap data processing. Then rip out the special-case code in bootscanner.l and bootstrap.c. This changes postgres.bki to the extent that array fields are now declared like proconfig = _text , rather than proconfig = text[] , No documentation update, since the SGML docs didn't mention any of this in the first place, and it's all pretty transparent to writers of catalog header files anyway. John Naylor Discussion: https://postgr.es/m/CAJVSVGUNao=-Q2-vAN3PYcdF5tnL5JAHwGwzZGuYHtq+Mk_9ng@mail.gmail.com
Diffstat (limited to 'src/include/bootstrap/bootstrap.h')
-rw-r--r--src/include/bootstrap/bootstrap.h2
1 files changed, 0 insertions, 2 deletions
diff --git a/src/include/bootstrap/bootstrap.h b/src/include/bootstrap/bootstrap.h
index 4f4129419f2..7856669ff91 100644
--- a/src/include/bootstrap/bootstrap.h
+++ b/src/include/bootstrap/bootstrap.h
@@ -44,8 +44,6 @@ extern void InsertOneTuple(Oid objectid);
extern void InsertOneValue(char *value, int i);
extern void InsertOneNull(int i);
-extern char *MapArrayTypeName(const char *s);
-
extern void index_register(Oid heap, Oid ind, IndexInfo *indexInfo);
extern void build_indices(void);