Re: arrays as pl/perl input arguments [PATCH] - Mailing list pgsql-hackers

From Alex Hunsaker
Subject Re: arrays as pl/perl input arguments [PATCH]
Date
Msg-id AANLkTimpw_YahdCXY8or=3mgipo_AajGGi40EzWVbO+4@mail.gmail.com
Whole thread Raw
In response to Re: arrays as pl/perl input arguments [PATCH]  (Alexey Klyukin <alexk@commandprompt.com>)
Responses Re: arrays as pl/perl input arguments [PATCH]  (Alexey Klyukin <alexk@commandprompt.com>)
List pgsql-hackers
On Thu, Jan 27, 2011 at 03:38, Alexey Klyukin <alexk@commandprompt.com> wrote:
> Hi,
>
> On Jan 27, 2011, at 9:31 AM, Alex Hunsaker wrote:
>
>> Find attached v3 of the patch.  changes include:
>> - fix deep recursion due to accidental reversal of check in encode_array_literal
>> - add proper support for stringifying composite/row types.  I did not
>> find a good way to quote these from the perl on the fly, so instead we
>> compute it the same way we used to and store the string inside the new
>> object along with the array :(.
>> - misc whitespace and code touchups
>> <pg_to_perl_arrays_v3.patch.gz>
>
>
> Nice improvement. It passes all the regression tests on my OS X system. I have only a minor suggestion, I think
is_arrayis worth mentioning in the utility functions chapter of the pl/perl documentation, it would be also more clear
touse it in regression tests as opposed to manually checking whether the ref is equal to
 'PostgreSQL::InServer::ARRAY'.

Wait a second...  Just who is reviewing who's patch? :P

Both done in the attached.  I also renamed is_array() to
is_array_ref() for clarity (hopefully).

Attachment

pgsql-hackers by date:

Previous
From: Magnus Hagander
Date:
Subject: pg_upgrade fails for non-postgres user
Next
From: Andrew Dunstan
Date:
Subject: Re: mingw format warnings