Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit d5f43a1

Browse files
committed
Remove use of perl parent module in Cluster.pm
Commit fb16d2c used the old but not quite old enough parent module, which dates to perl version 5.10.1 as a core module. We still have a dinosaur or two running older versions of perl, so rather than require an upgrade in those we simply do in place what parent.pm's import() would have done for us. Reviewed by Tom Lane Discussion: https://postgr.es/m/474104.1648685981@sss.pgh.pa.us
1 parent fea1cc4 commit d5f43a1

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/test/perl/PostgreSQL/Test/Cluster.pm

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2918,7 +2918,10 @@ sub corrupt_page_checksum
29182918

29192919
package PostgreSQL::Test::Cluster::V_11; ## no critic (ProhibitMultiplePackages)
29202920

2921-
use parent -norequire, qw(PostgreSQL::Test::Cluster);
2921+
# parent.pm is not present in all perl versions before 5.10.1, so instead
2922+
# do directly what it would do for this:
2923+
# use parent -norequire, qw(PostgreSQL::Test::Cluster);
2924+
push @PostgreSQL::Test::Cluster::V_11::ISA, 'PostgreSQL::Test::Cluster';
29222925

29232926
# https://www.postgresql.org/docs/11/release-11.html
29242927

@@ -2945,7 +2948,8 @@ sub init
29452948

29462949
package PostgreSQL::Test::Cluster::V_10; ## no critic (ProhibitMultiplePackages)
29472950

2948-
use parent -norequire, qw(PostgreSQL::Test::Cluster::V_11);
2951+
# use parent -norequire, qw(PostgreSQL::Test::Cluster::V_11);
2952+
push @PostgreSQL::Test::Cluster::V_10::ISA, 'PostgreSQL::Test::Cluster::V_11';
29492953

29502954
# https://www.postgresql.org/docs/10/release-10.html
29512955

0 commit comments

Comments
 (0)