Re: generating bootstrap entries for array types

Dagfinn Ilmari Mannsåker <ilmari@ilmari.org>

From: ilmari@ilmari.org (Dagfinn Ilmari Mannsåker )
To: John Naylor <jcnaylor@gmail.com>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2018-09-20T11:53:30Z
Lists: pgsql-hackers

Attachments

Hi again John,

ilmari@ilmari.org (Dagfinn Ilmari Mannsåker) writes:

> Doing this in genbki.pl makes DBD::Pg lose its array type information,
> since it uses Catalog::ParseData() to get it
> (https://github.com/bucardo/dbdpg/blob/master/types.c#L439).  May I
> suggest moving gen_array_types() to Catalog.pm and calling it from
> ParseData() if the input file is pg_type.dat, so that it always returns
> complete data?

Attached is a proposed revision of this patch that does the above.  It
passes check-world, reformat_dat_file.pl still works, and DBD::Pg is
still able to get the array type information.

Thanks,

- ilmari
-- 
"I use RMS as a guide in the same way that a boat captain would use
 a lighthouse.  It's good to know where it is, but you generally
 don't want to find yourself in the same spot." - Tollef Fog Heen

Commits

  1. Teach genbki.pl to auto-generate pg_type entries for array types.