Skip to content

Commit 5079c52

Browse files
cpan/Scalar-List-Utils - Update to version 1.70, removing customizations and bad versioning
1.70 -- 2025-07-30 [CHANGES] * Reïnstate handling of apostrophy in package names, as it was added back to perl at version 5.41.6
1 parent 463db48 commit 5079c52

File tree

8 files changed

+21
-42
lines changed

8 files changed

+21
-42
lines changed

Porting/Maintainers.pl

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1009,17 +1009,9 @@ package Maintainers;
10091009
},
10101010

10111011
'Scalar::Util' => {
1012-
'DISTRIBUTION' => 'PEVANS/Scalar-List-Utils-1.69.tar.gz',
1013-
'SYNCINFO' => 'jkeenan on Thu Apr 10 21:01:49 2025',
1012+
'DISTRIBUTION' => 'PEVANS/Scalar-List-Utils-1.70.tar.gz',
1013+
'SYNCINFO' => 'ether on Wed Jul 30 16:32:42 2025',
10141014
'FILES' => q[cpan/Scalar-List-Utils],
1015-
'CUSTOMIZED' => [
1016-
'ListUtil.xs',
1017-
'lib/List/Util.pm',
1018-
'lib/List/Util/XS.pm',
1019-
'lib/Scalar/Util.pm',
1020-
'lib/Sub/Util.pm',
1021-
't/exotic_names.t'
1022-
],
10231015
},
10241016

10251017
'Search::Dict' => {

cpan/Scalar-List-Utils/ListUtil.xs

Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1852,10 +1852,10 @@ CODE:
18521852
#ifdef SvVOK
18531853
SvGETMAGIC(sv);
18541854
ST(0) = boolSV(SvVOK(sv));
1855-
XSRETURN(1);
18561855
#else
1857-
croak("vstrings are not implemented in this release of perl");
1856+
ST(0) = boolSV(0);
18581857
#endif
1858+
XSRETURN(1);
18591859

18601860
SV *
18611861
looks_like_number(sv)
@@ -1951,8 +1951,10 @@ PREINIT:
19511951
STRLEN namelen;
19521952
const char* nameptr = SvPV(name, namelen);
19531953
int utf8flag = SvUTF8(name);
1954+
#if PERL_VERSION_LT(5, 41, 3) || PERL_VERSION_GT(5, 41, 5)
19541955
int quotes_seen = 0;
19551956
bool need_subst = FALSE;
1957+
#endif
19561958
PPCODE:
19571959
if (!SvROK(sub) && SvGMAGICAL(sub))
19581960
mg_get(sub);
@@ -1975,18 +1977,23 @@ PPCODE:
19751977
if (s > nameptr && *s == ':' && s[-1] == ':') {
19761978
end = s - 1;
19771979
begin = ++s;
1980+
#if PERL_VERSION_LT(5, 41, 3) || PERL_VERSION_GT(5, 41, 5)
19781981
if (quotes_seen)
19791982
need_subst = TRUE;
1983+
#endif
19801984
}
1985+
#if PERL_VERSION_LT(5, 41, 3) || PERL_VERSION_GT(5, 41, 5)
19811986
else if (s > nameptr && *s != '\0' && s[-1] == '\'') {
19821987
end = s - 1;
19831988
begin = s;
19841989
if (quotes_seen++)
19851990
need_subst = TRUE;
19861991
}
1992+
#endif
19871993
}
19881994
s--;
19891995
if (end) {
1996+
#if PERL_VERSION_LT(5, 41, 3) || PERL_VERSION_GT(5, 41, 5)
19901997
SV* tmp;
19911998
if (need_subst) {
19921999
STRLEN length = end - nameptr + quotes_seen - (*end == '\'' ? 1 : 0);
@@ -2006,6 +2013,7 @@ PPCODE:
20062013
stash = gv_stashpvn(left, length, GV_ADD | utf8flag);
20072014
}
20082015
else
2016+
#endif
20092017
stash = gv_stashpvn(nameptr, end - nameptr, GV_ADD | utf8flag);
20102018
nameptr = begin;
20112019
namelen -= begin - nameptr;
@@ -2101,20 +2109,9 @@ BOOT:
21012109
HV *lu_stash = gv_stashpvn("List::Util", 10, TRUE);
21022110
GV *rmcgv = *(GV**)hv_fetch(lu_stash, "REAL_MULTICALL", 14, TRUE);
21032111
SV *rmcsv;
2104-
#if !defined(SvVOK)
2105-
HV *su_stash = gv_stashpvn("Scalar::Util", 12, TRUE);
2106-
GV *vargv = *(GV**)hv_fetch(su_stash, "EXPORT_FAIL", 11, TRUE);
2107-
AV *varav;
2108-
if(SvTYPE(vargv) != SVt_PVGV)
2109-
gv_init(vargv, su_stash, "Scalar::Util", 12, TRUE);
2110-
varav = GvAVn(vargv);
2111-
#endif
21122112
if(SvTYPE(rmcgv) != SVt_PVGV)
21132113
gv_init(rmcgv, lu_stash, "List::Util", 10, TRUE);
21142114
rmcsv = GvSVn(rmcgv);
2115-
#ifndef SvVOK
2116-
av_push(varav, newSVpv("isvstring",9));
2117-
#endif
21182115
#ifdef REAL_MULTICALL
21192116
sv_setsv(rmcsv, &PL_sv_yes);
21202117
#else

cpan/Scalar-List-Utils/lib/List/Util.pm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ our @EXPORT_OK = qw(
1616
sample shuffle uniq uniqint uniqnum uniqstr zip zip_longest zip_shortest mesh mesh_longest mesh_shortest
1717
head tail pairs unpairs pairkeys pairvalues pairmap pairgrep pairfirst
1818
);
19-
our $VERSION = "1.68_01";
19+
our $VERSION = "1.70";
2020
our $XS_VERSION = $VERSION;
2121
$VERSION =~ tr/_//d;
2222

cpan/Scalar-List-Utils/lib/List/Util/XS.pm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ use strict;
33
use warnings;
44
use List::Util;
55

6-
our $VERSION = "1.68_01"; # FIXUP
6+
our $VERSION = "1.70"; # FIXUP
77
$VERSION =~ tr/_//d; # FIXUP
88

99
1;

cpan/Scalar-List-Utils/lib/Scalar/List/Utils.pm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ package Scalar::List::Utils;
22
use strict;
33
use warnings;
44

5-
our $VERSION = "1.69";
5+
our $VERSION = "1.70";
66
$VERSION =~ tr/_//d;
77

88
1;

cpan/Scalar-List-Utils/lib/Scalar/Util.pm

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ our @EXPORT_OK = qw(
1717
dualvar isdual isvstring looks_like_number openhandle readonly set_prototype
1818
tainted
1919
);
20-
our $VERSION = "1.68_01";
20+
our $VERSION = "1.70";
2121
$VERSION =~ tr/_//d;
2222

2323
require List::Util; # List::Util loads the XS
@@ -36,16 +36,6 @@ if( $] >= 5.040 ) {
3636
*isweak = \&{ $builtins->{is_weak} }; # renamed
3737
}
3838

39-
# populating @EXPORT_FAIL is done in the XS code
40-
sub export_fail {
41-
if (grep { /^isvstring$/ } @_ ) {
42-
require Carp;
43-
Carp::croak("Vstrings are not implemented in this version of perl");
44-
}
45-
46-
@_;
47-
}
48-
4939
# set_prototype has been moved to Sub::Util with a different interface
5040
sub set_prototype(&$)
5141
{

cpan/Scalar-List-Utils/lib/Sub/Util.pm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ our @EXPORT_OK = qw(
1515
subname set_subname
1616
);
1717

18-
our $VERSION = "1.68_01";
18+
our $VERSION = "1.70";
1919
$VERSION =~ tr/_//d;
2020

2121
require List::Util; # as it has the XS

cpan/Scalar-List-Utils/t/exotic_names.t

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ sub caller3_ok {
4545
),
4646
);
4747

48-
$expected =~ s/'/::/g if $] < 5.037009 || $] >= 5.041_004;
48+
$expected =~ s/'/::/g if $] < 5.041_003 || $] >= 5.041_006;
4949

5050
# this is apparently how things worked before 5.16
5151
utf8::encode($expected) if $] < 5.016 and $ord > 255;
@@ -71,8 +71,8 @@ my @ordinal = (
7171
# 5.14 is the first perl to start properly handling \0 in identifiers
7272
($] >= 5.014 ? ( 0 ) : ()),
7373
1 .. 38,
74-
# single quote ' separators are deprecated in 5.37.9
75-
($] < 5.037009 || $] >= 5.041_004 ? ( 39 ) : ()),
74+
# single quote ' separators are deprecated in 5.37.9, removed in 5.41.3, readded in 5.41.6
75+
($] < 5.037_009 || $] >= 5.041_006 ? ( 39 ) : ()),
7676
40 .. 255,
7777
# Unicode in 5.6 is not sane (crashes etc)
7878
($] >= 5.008 ? (
@@ -85,7 +85,7 @@ my @ordinal = (
8585

8686
my $legal_ident_char = join('',
8787
"A-Z_a-z0-9",
88-
($] < 5.037009 || $] >= 5.041_004 ? q['] : ()),
88+
($] < 5.037_009 || $] >= 5.041_006 ? q['] : ()),
8989
($] > 5.008 ? (
9090
map chr, 0x100, 0x498
9191
) : ()),

0 commit comments

Comments
 (0)