Re: Unexpected plperl difference between 8.4 and 9.1
От | Kaare Rasmussen |
---|---|
Тема | Re: Unexpected plperl difference between 8.4 and 9.1 |
Дата | |
Msg-id | 50333A2D.8010407@jasonic.dk обсуждение исходный текст |
Ответ на | Re: Unexpected plperl difference between 8.4 and 9.1 (Tom Lane <tgl@sss.pgh.pa.us>) |
Список | pgsql-hackers |
On 2012-08-20 18:36, Tom Lane wrote: > Alvaro Herrera<alvherre@2ndquadrant.com> writes: >> Excerpts from Alex Hunsaker's message of lun ago 20 12:03:11 -0400 2012: >>> Hrm seems to work for me. What version of perl is this? >>> $ perl -V >>> Summary of my perl5 (revision 5 version 16 subversion 0) configuration: >> I can reproduce the failure with 5.14.2 > Smells like a Perl bug to me. Has anybody attempted to reproduce this > just in Perl itself, not PL/Perl? > > regards, tom lane > > I can't reproduce it in perl, but it's in PL/perl from 9.2 beta built with perl 5.14.2. Currently I don't have another perl with libperl installed. This produces the error: CREATE OR REPLACE FUNCTION test1() RETURNS SETOF NUMERIC AS $BODY$ use strict; use warnings; for (0..9) { my $rand = rand(); $rand =~ m/(.*)/; return_next($1); } return; $BODY$ LANGUAGE plperl; Adding 'elog(NOTICE, "rand:$rand, :$1");' after the capture maked the error go away. Do does changining the return_next statemtnt to 'my $retvalue=$1;return_next($retvalue);'
В списке pgsql-hackers по дате отправления: