Skip site navigation (1) Skip section navigation (2)

Removing typename from A_Const (was: Empty arrays with ARRAY[])

From: "Brendan Jurd" <direvus(at)gmail(dot)com>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers(at)postgresql(dot)org, pgsql-patches(at)postgresql(dot)org
Subject: Removing typename from A_Const (was: Empty arrays with ARRAY[])
Date: 2008-04-14 21:23:13
Message-ID: 37ed240d0804141423y36a29943r20bab71df9531140@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-hackerspgsql-patches
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Fri, Mar 21, 2008 at 7:47 AM, Tom Lane  wrote:
>  I didn't do anything about removing A_Const's typename field, but I'm
>  thinking that would be a good cleanup patch.
>

Here's my attempt to remove the typename field from A_Const.  There
were a few places (notably flatten_set_variable_args() in guc.c, and
typenameTypeMod() in parse_type.c) where the code expected to see an
A_Const with a typename, and I had to adjust for an A_Const within a
TypeCast.  Nonetheless, there was an overall net reduction of 34 lines
of code, so I think this was a win.

All regression tests passed on x86_64 gentoo.

Added to May CommitFest.

Cheers,
BJ
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.7 (GNU/Linux)
Comment: http://getfiregpg.org

iD8DBQFIA8s/5YBsbHkuyV0RAlMdAJ0dWdoZd5cypvInAR2msO8XA8qqxACeILSw
bCI2TGAQI3m3TBoJspvV4OQ=
=dGP9
-----END PGP SIGNATURE-----

Attachment: aconst-no-typename_0.diff.bz2
Description: application/x-bzip2 (5.3 KB)

Responses

pgsql-hackers by date

Next:From: Brendan JurdDate: 2008-04-14 21:43:43
Subject: Re: Lessons from commit fest
Previous:From: Bruce MomjianDate: 2008-04-14 21:15:51
Subject: Re: Lessons from commit fest

pgsql-patches by date

Next:From: Alvaro HerreraDate: 2008-04-14 23:57:53
Subject: Re: explicit tracking of ActiveSnapshot
Previous:From: Bruce MomjianDate: 2008-04-14 17:52:38
Subject: Terminating a backend

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group