Skip to content

Commit 0c81a5c

Browse files
committed
remove use of ' as a package separator
2 parents 3e14b2f + 83d4e74 commit 0c81a5c

File tree

33 files changed

+147
-319
lines changed

33 files changed

+147
-319
lines changed

cpan/Scalar-List-Utils/ListUtil.xs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1947,8 +1947,10 @@ PREINIT:
19471947
STRLEN namelen;
19481948
const char* nameptr = SvPV(name, namelen);
19491949
int utf8flag = SvUTF8(name);
1950+
#if PERL_VERSION_LT(5, 41, 3)
19501951
int quotes_seen = 0;
19511952
bool need_subst = FALSE;
1953+
#endif
19521954
PPCODE:
19531955
if (!SvROK(sub) && SvGMAGICAL(sub))
19541956
mg_get(sub);
@@ -1971,18 +1973,23 @@ PPCODE:
19711973
if (s > nameptr && *s == ':' && s[-1] == ':') {
19721974
end = s - 1;
19731975
begin = ++s;
1976+
#if PERL_VERSION_LT(5, 41, 3)
19741977
if (quotes_seen)
19751978
need_subst = TRUE;
1979+
#endif
19761980
}
1981+
#if PERL_VERSION_LT(5, 41, 3)
19771982
else if (s > nameptr && *s != '\0' && s[-1] == '\'') {
19781983
end = s - 1;
19791984
begin = s;
19801985
if (quotes_seen++)
19811986
need_subst = TRUE;
19821987
}
1988+
#endif
19831989
}
19841990
s--;
19851991
if (end) {
1992+
#if PERL_VERSION_LT(5, 41, 3)
19861993
SV* tmp;
19871994
if (need_subst) {
19881995
STRLEN length = end - nameptr + quotes_seen - (*end == '\'' ? 1 : 0);
@@ -2002,6 +2009,7 @@ PPCODE:
20022009
stash = gv_stashpvn(left, length, GV_ADD | utf8flag);
20032010
}
20042011
else
2012+
#endif
20052013
stash = gv_stashpvn(nameptr, end - nameptr, GV_ADD | utf8flag);
20062014
nameptr = begin;
20072015
namelen -= begin - nameptr;

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.63";
19+
our $VERSION = "1.63_01";
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.63"; # FIXUP
6+
our $VERSION = "1.63_01"; # FIXUP
77
$VERSION =~ tr/_//d; # FIXUP
88

99
1;

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

Lines changed: 1 addition & 1 deletion
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.63";
20+
our $VERSION = "1.63_01";
2121
$VERSION =~ tr/_//d;
2222

2323
require List::Util; # List::Util loads the XS

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.63";
18+
our $VERSION = "1.63_01";
1919
$VERSION =~ tr/_//d;
2020

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

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

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

48-
$expected =~ s/'/::/g;
48+
$expected =~ s/'/::/g if $] < 5.041_003;
4949

5050
# this is apparently how things worked before 5.16
5151
utf8::encode($expected) if $] < 5.016 and $ord > 255;
@@ -83,7 +83,8 @@ push @ordinal,
8383

8484
plan tests => @ordinal * 2 * 3;
8585

86-
my $legal_ident_char = "A-Z_a-z0-9'";
86+
my $legal_ident_char = "A-Z_a-z0-9";
87+
$legal_ident_char .= "'" if $] < 5.041_003;
8788
$legal_ident_char .= join '', map chr, 0x100, 0x498
8889
unless $] < 5.008;
8990

cpan/parent/lib/parent.pm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package parent;
22
use strict;
33

4-
our $VERSION = '0.241';
4+
our $VERSION = '0.241_001';
55

66
sub import {
77
my $class = shift;

cpan/parent/t/compile-time-file.t

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ use lib 't/lib';
2424

2525
{
2626
package Child3;
27-
use parent "Dummy'Outside";
27+
use if $] < 5.041_003, parent => "Dummy'Outside";
2828
}
2929

3030
my $obj = {};
@@ -39,9 +39,13 @@ isa_ok $obj, 'Dummy::InlineChild';
3939
can_ok $obj, 'exclaim';
4040
is $obj->exclaim, "I CAN FROM Dummy::InlineChild", 'Inheritance is set up correctly for inlined classes';
4141

42+
SKIP:
43+
{
44+
skip "No ' in names from 5.041_003", 3 if $] >= 5.041_003;
4245
$obj = {};
4346
bless $obj, 'Child3';
4447
isa_ok $obj, 'Dummy::Outside';
4548
can_ok $obj, 'exclaim';
4649
is $obj->exclaim, "I CAN FROM Dummy::Outside", "Inheritance is set up correctly for classes inherited from via '";
4750

51+
}

embed.fnc

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2995,12 +2995,6 @@ EXpx |char * |scan_word |NN char *s \
29952995
|STRLEN destlen \
29962996
|int allow_package \
29972997
|NN STRLEN *slp
2998-
EXpx |char * |scan_word6 |NN char *s \
2999-
|NN char *dest \
3000-
|STRLEN destlen \
3001-
|int allow_package \
3002-
|NN STRLEN *slp \
3003-
|bool warn_tick
30042998
Cp |U32 |seed
30052999
: Only used by perl.c/miniperl.c, but defined in caretx.c
30063000
ep |void |set_caret_X
@@ -5894,8 +5888,7 @@ S |void |parse_ident |NN char **s \
58945888
|NN char * const e \
58955889
|int allow_package \
58965890
|bool is_utf8 \
5897-
|bool check_dollar \
5898-
|bool tick_warn
5891+
|bool check_dollar
58995892
S |int |pending_ident
59005893
RS |char * |scan_const |NN char *start
59015894
RS |char * |scan_formline |NN char *s

embed.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1629,7 +1629,7 @@
16291629
# define lop(a,b,c) S_lop(aTHX_ a,b,c)
16301630
# define missingterm(a,b) S_missingterm(aTHX_ a,b)
16311631
# define no_op(a,b) S_no_op(aTHX_ a,b)
1632-
# define parse_ident(a,b,c,d,e,f,g) S_parse_ident(aTHX_ a,b,c,d,e,f,g)
1632+
# define parse_ident(a,b,c,d,e,f) S_parse_ident(aTHX_ a,b,c,d,e,f)
16331633
# define pending_ident() S_pending_ident(aTHX)
16341634
# define scan_const(a) S_scan_const(aTHX_ a)
16351635
# define scan_formline(a) S_scan_formline(aTHX_ a)
@@ -1765,7 +1765,6 @@
17651765
# define report_uninit(a) Perl_report_uninit(aTHX_ a)
17661766
# define scan_str(a,b,c,d,e) Perl_scan_str(aTHX_ a,b,c,d,e)
17671767
# define scan_word(a,b,c,d,e) Perl_scan_word(aTHX_ a,b,c,d,e)
1768-
# define scan_word6(a,b,c,d,e,f) Perl_scan_word6(aTHX_ a,b,c,d,e,f)
17691768
# define skipspace_flags(a,b) Perl_skipspace_flags(aTHX_ a,b)
17701769
# define sv_magicext_mglob(a) Perl_sv_magicext_mglob(aTHX_ a)
17711770
# define sv_only_taint_gmagic Perl_sv_only_taint_gmagic

0 commit comments

Comments
 (0)