From 55d0d56f62fd6ff7d88bbeb728ab192523b35bdc Mon Sep 17 00:00:00 2001 From: Chris 'BinGOs' Williams Date: Fri, 25 Oct 2019 15:21:25 +0100 Subject: [PATCH 1/2] RT#130664 test failures with v5.31.5 As per perldelta entry for v5.31.5 https://metacpan.org/pod/release/SHAY/perl-5.31.5/pod/perldelta.pod#Incompatible-Changes --- lib/POE/Kernel.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/POE/Kernel.pm b/lib/POE/Kernel.pm index f042ad0..2d7e400 100644 --- a/lib/POE/Kernel.pm +++ b/lib/POE/Kernel.pm @@ -365,7 +365,7 @@ BEGIN { no strict 'refs'; local $^W = 0; local $SIG{__WARN__} = sub { }; # redefine - *$const = sub () { $value }; + *$const = sub () { return $value }; } # TRACE_FILENAME is special. -- 2.1.4 From 39bfe5ffac6be8bd573e749eabc72042c1eede77 Mon Sep 17 00:00:00 2001 From: Chris 'BinGOs' Williams Date: Tue, 29 Oct 2019 10:09:52 +0000 Subject: [PATCH 2/2] Corrected previous commit as per tonyc's suggestion --- lib/POE/Kernel.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/POE/Kernel.pm b/lib/POE/Kernel.pm index 2d7e400..27781f9 100644 --- a/lib/POE/Kernel.pm +++ b/lib/POE/Kernel.pm @@ -365,7 +365,8 @@ BEGIN { no strict 'refs'; local $^W = 0; local $SIG{__WARN__} = sub { }; # redefine - *$const = sub () { return $value }; + my $tmp = $value; + *$const = sub () { $tmp }; } # TRACE_FILENAME is special. -- 2.1.4