File: DeprecatedFeatures.run

package info (click to toggle)
libperl-critic-freenode-perl 0.028-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 416 kB
  • sloc: perl: 986; makefile: 2
file content (171 lines) | stat: -rw-r--r-- 2,595 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
## name GoodFeatures
## failures 0
## cut

my $x : Foo = 1;
use UNIVERSAL ();
UNIVERSAL->can('foo');
use POSIX ();
for my $foo (qw(foo bar)) { ... }
1 for qw(foo bar);
do { ... };
do '...';
do $foo;
isalnum $foo;
isalpha $foo;
iscntrl $foo;
isdigit $foo;
isgraph $foo;
islower $foo;
isprint $foo;
ispunct $foo;
isspace $foo;
isupper $foo;
isxdigit $foo;
tmpnam $foo;
defined $foo;
defined $foo[0];
defined $foo{bar};
defined &foo;
$obj->defined(@foo);
foo ? bar ? 'foo' : 'bar' : 'baz';
foo ? bar ? foo : bar : baz;
$foo =~ m?foo?;
$foo =~ s?foo?bar?;
"\N{FOO BAR}";
`\N{FOO BAR}`;
qx(\N{FOO BAR});
qq{\N{FOO BAR}};
qr/\N{FOO BAR}/;
m'\N{FOO BAR}';
s{\N{FOO BAR}}{};
keys %hash;
keys %$href;
keys(%{$href});
keys %{$foo{bar}[5]};
keys $foo->{bar}[5]->%*;
keys $foo->{bar}[5]->%* > 4;
shift(@array);
shift @$aref;
shift @{$aref};
shift(@{$foo->{bar}[5]});
shift $foo->{bar}[5]->@*;
shift;
shift();
Foo->shift($foo);
require Foo::Bar;
use Foo::Bar;
no Foo::Bar;
require '::Foo::Bar.pm';
qr/\cT\\C/;
m/\cT\\C/;
chdir;
chdir();
chdir 'foo';
chdir(getcwd);
<< 'foo';
foo
<<'';

<<foo;
foo
foo << (bar);
foo << +bar;

## name BadFeatures
## failures 51
## cut

$[ = 1;
my $x := 1;
UNIVERSAL->import;
use UNIVERSAL;
use UNIVERSAL 'foo';
for my $foo qw(foo bar) { ... }
do foo(...);
do &foo(...);
do $foo(...);
POSIX::isalnum($foo);
POSIX::isalpha($foo);
POSIX::iscntrl($foo);
POSIX::isdigit($foo);
POSIX::isgraph($foo);
POSIX::islower($foo);
POSIX::isprint($foo);
POSIX::ispunct($foo);
POSIX::isspace($foo);
POSIX::isupper($foo);
POSIX::isxdigit($foo);
POSIX::tmpnam($foo);
defined @foo;
defined %foo;
defined(@foo);
defined(%foo);
$foo =~ ?foo?;
"\N{FOO BAR}";
`\N{FOO BAR}`;
qq{\N{FOO BAR}};
qx(\N{FOO BAR});
qr^\N{FOO BAR}^;
m<\N{FOO BAR}>;
s/\N{FOO BAR}//;
each $ref;
keys($ref);
pop $foo->{bar};
push $foo{bar}[0];
shift($foo->[5]);
splice $foo, $bar, $baz;
unshift $ref, @bar;
values $ref;
require ::Foo::Bar;
use ::Foo::Bar;
no ::Foo::Bar;
qr/\C/;
m/\C/;
chdir '';
chdir(qq());
chdir undef();
<<;

(<<);

{<<}

<< . bar;


## name POSIXDeprecations
## failures 12
## cut

use POSIX;
isalnum $foo;
isalpha $foo;
iscntrl $foo;
isdigit $foo;
isgraph $foo;
islower $foo;
isprint $foo;
ispunct $foo;
isspace $foo;
isupper $foo;
isxdigit $foo;
tmpnam $foo;

## name POSIXDeprecationsImported
## failures 12
## cut

use POSIX qw(isalnum isalpha iscntrl isdigit isgraph islower isprint ispunct isspace isupper isxdigit tmpnam);
isalnum $foo;
isalpha $foo;
iscntrl $foo;
isdigit $foo;
isgraph $foo;
islower $foo;
isprint $foo;
ispunct $foo;
isspace $foo;
isupper $foo;
isxdigit $foo;
tmpnam $foo;