This is a live mirror of the Perl 5 development currently hosted at
https://github.com/perl/perl5
https://perl5.git.perl.org
/
perl5.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
blame
|
history
|
raw
|
HEAD
Print a deprecation warning if downgrading to a use VERSION below v5.11
[perl5.git]
/
t
/
op
/
mydef.t
1
#!./perl -w
2
3
BEGIN {
4
chdir 't' if -d 't';
5
require './test.pl';
6
set_up_inc('../lib');
7
}
8
9
use strict;
10
11
eval 'my $_';
12
like $@, qr/^Can't use global \$_ in "my" at /;
13
14
{
15
# using utf8 allows $_ to be declared with 'my'
16
# GH #18449
17
use utf8;
18
eval 'my $_;';
19
like $@, qr/^Can't use global \$_ in "my" at /;
20
}
21
22
done_testing;