Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitd4c1618

Browse files
committed
Fix pl/perl test case so it will still work under Perl 5.36.
Perl 5.36 has reclassified the warning condition that this testcase used, so that the expected error fails to appear. Tweakthe test so it instead exercises a case that's handled the sameway in all Perl versions of interest.This appears to meet our standards for back-patching intoout-of-support branches: it changes no user-visible behaviorbut enables testing of old branches with newer tools.Hence, back-patch as far as 9.2.Dagfinn Ilmari Mannsåker, per report from Jitka Plesníková.Discussion:https://postgr.es/m/564579.1654093326@sss.pgh.pa.us
1 parent622ab6a commitd4c1618

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

‎src/pl/plperl/expected/plperl.out

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -644,9 +644,9 @@ DO $do$ use strict; my $name = "foo"; my $ref = $$name; $do$ LANGUAGE plperl;
644644
ERROR: Can't use string ("foo") as a SCALAR ref while "strict refs" in use at line 1.
645645
CONTEXT: PL/Perl anonymous code block
646646
-- check that we can "use warnings" (in this case to turn a warn into an error)
647-
-- yields "ERROR: Useless use of sort inscalar context."
648-
DO $do$ use warnings FATAL => qw(void) ; my @y;my $x =sort @y; 1; $do$ LANGUAGE plperl;
649-
ERROR: Useless use of sort inscalar context at line 1.
647+
-- yields "ERROR: Useless use of sort invoid context."
648+
DO $do$ use warnings FATAL => qw(void) ; my @y; sort @y; 1; $do$ LANGUAGE plperl;
649+
ERROR: Useless use of sort invoid context at line 1.
650650
CONTEXT: PL/Perl anonymous code block
651651
-- make sure functions marked as VOID without an explicit return work
652652
CREATE OR REPLACE FUNCTION myfuncs() RETURNS void AS $$

‎src/pl/plperl/sql/plperl.sql

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -420,8 +420,8 @@ DO $$ use blib; $$ LANGUAGE plperl;
420420
DO $do$ use strict; my $name="foo"; my $ref= $$name; $do$ LANGUAGE plperl;
421421

422422
-- check that we can "use warnings" (in this case to turn a warn into an error)
423-
-- yields "ERROR: Useless use of sort inscalar context."
424-
DO $do$ use warnings FATAL=> qw(void) ; my @y;my $x=sort @y;1; $do$ LANGUAGE plperl;
423+
-- yields "ERROR: Useless use of sort invoid context."
424+
DO $do$ use warnings FATAL=> qw(void) ; my @y; sort @y;1; $do$ LANGUAGE plperl;
425425

426426
-- make sure functions marked as VOID without an explicit return work
427427
CREATE OR REPLACEFUNCTIONmyfuncs() RETURNS voidAS $$

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp