mirror of
https://github.com/postgres/postgres.git
synced 2025-04-29 13:56:47 +03:00
Label the contents of pg_*_d.h files a little better.
Make genbki.pl emit some boilerplate comments identifying the sections of the pg_*_d.h files that it generates. This is in hopes of making them slightly more readable, in case people look at those files and not the pg_*.h/pg_*.dat originals. Discussion: https://postgr.es/m/1134562.1742507765@sss.pgh.pa.us
This commit is contained in:
parent
69273b818b
commit
cd72c1b76e
@ -480,6 +480,8 @@ foreach my $catname (@catnames)
|
||||
|
||||
EOM
|
||||
|
||||
printf $def "/* Macros related to the structure of $catname */\n\n";
|
||||
|
||||
# Emit OID macros for catalog's OID and rowtype OID, if wanted
|
||||
printf $def "#define %s %s\n",
|
||||
$catalog->{relation_oid_macro}, $catalog->{relation_oid}
|
||||
@ -561,6 +563,7 @@ EOM
|
||||
print $def "\n#define Natts_$catname $attnum\n\n";
|
||||
|
||||
# Emit client code copied from source header
|
||||
printf $def "/* Definitions copied from ${catname}.h */\n\n";
|
||||
foreach my $line (@{ $catalog->{client_code} })
|
||||
{
|
||||
print $def $line;
|
||||
@ -573,6 +576,9 @@ EOM
|
||||
print $bki "open $catname\n";
|
||||
}
|
||||
|
||||
printf $def
|
||||
"\n/* OID symbols for objects defined in ${catname}.dat */\n\n";
|
||||
|
||||
# For pg_attribute.h, we generate data entries ourselves.
|
||||
if ($catname eq 'pg_attribute')
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user