lib/B/Keywords.pm

filter: Statementstmt 100% 61 / 61 Branchbran 48.4% 32 / 66 Conditioncond 31.2% 15 / 48 MC/DCmcdc 0.0% 0 / 26 Subroutinesub 100% 15 / 15 Podpod n/a totaltotal 56.9% 123 / 216 CC 1 SCAR 0.0
CC
1
Cov
62%
BEGIN
1.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.0
↑ Summary
1 ## no critic (PodSections,UseWarnings,Interpolation,EndWithOne,NoisyQuotes)
2  
3 package B::Keywords;
4  
5 3 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
6  
7 3 require Exporter;
8 3 *import = *import = \&Exporter::import;
9  
10 3 ▶use vars qw( @EXPORT_OK %EXPORT_TAGS );
Subroutine BEGIN: called CC=1 SCAR=0.0
11 3 @EXPORT_OK = qw( @Scalars @Arrays @Hashes @Filehandles @Symbols
12 @Functions @Barewords @TieIOMethods @UNIVERSALMethods
13 @ExporterSymbols );
14 3 %EXPORT_TAGS = ( 'all' => \@EXPORT_OK );
15  
16 3 ▶use vars '$VERSION';
Subroutine BEGIN: called CC=1 SCAR=0.0
17 3 $VERSION = '1.29';
18 3 ▶my $CPERL = $^V =~ /c$/ ? 1 : 0;
Branch: 1 branch
BranchTrueFalseTotal
$^V =~ /c$/ ? : 0 3 3
19  
20 3 ▶use vars '@Scalars';
Subroutine BEGIN: called CC=1 SCAR=0.0
21 3 ▶@Scalars = (
Branch: 1 branch
BranchTrueFalseTotal
$] < 5.008001 ? : 0 3 3
22 qw( $a
23 $b
24 $_ $ARG
25 $& $MATCH
26 $` $PREMATCH
27 $' $POSTMATCH
28 $+ $LAST_PAREN_MATCH ),
29 ($] < 5.008001 ?
30 qw( $* $MULTILINE_MATCHING) : ()),
31 qw( $. $INPUT_LINE_NUMBER $NR
32 $/ $INPUT_RECORD_SEPARATOR $RS
33 $| $OUTPUT_AUTOFLUSH ),
34 '$,', qw( $OUTPUT_FIELD_SEPARATOR $OFS ),
35 '$\\', qw( $OUTPUT_RECORD_SEPARATOR $ORS ),
36 qw(
37 $" $LIST_SEPARATOR
38 $; $SUBSCRIPT_SEPARATOR $SUBSEP
39 ), '$#', qw( $OFMT
40 $% $FORMAT_PAGE_NUMBER
41 $= $FORMAT_LINES_PER_PAGE
42 $- $FORMAT_LINES_LEFT
43 $~ $FORMAT_NAME
44 $^ $FORMAT_TOP_NAME
45 $: $FORMAT_LINE_BREAK_CHARACTERS
46 $? $CHILD_ERROR $^CHILD_ERROR_NATIVE
47 $! $ERRNO $OS_ERROR
48 $@ $EVAL_ERROR
49 $$ $PROCESS_ID $PID
50 $< $REAL_USER_ID $UID
51 $> $EFFECTIVE_USER_ID $EUID ),
52 '$(', qw( $REAL_GROUP_ID $GID ),
53 '$)', qw( $EFFECTIVE_GROUP_ID $EGID
54 $0 $PROGRAM_NAME
55 $[
56 $]
57 $^A $ACCUMULATOR
58 $^C $COMPILING
59 $^CHILD_ERROR_NATIVE
60 $^D $DEBUGGING
61 $^E $EXTENDED_OS_ERROR
62 $^ENCODING
63 $^F $SYSTEM_FD_MAX
64 $^GLOBAL_PHASE
65 $^H
66 $^I $INPLACE_EDIT
67 $^L $FORMAT_FORMFEED
68 $^LAST_FH
69 $^M
70 $^MATCH
71 $^N $LAST_SUBMATCH_RESULT
72 $^O $OSNAME
73 $^OPEN
74 $^P $PERLDB
75 $^PREMATCH $^POSTMATCH
76 $^R $LAST_REGEXP_CODE_RESULT
77 $^RE_DEBUG_FLAGS
78 $^RE_TRIE_MAXBUF
79 $^S $EXCEPTIONS_BEING_CAUGHT
80 $^T $BASETIME
81 $^TAINT
82 $^UNICODE
83 $^UTF8CACHE
84 $^UTF8LOCALE
85 $^V $PERL_VERSION
86 $^W $WARNING $^WARNING_BITS
87 $^WIDE_SYSTEM_CALLS
88 $^WIN32_SLOPPY_STAT
89 $^X $EXECUTABLE_NAME
90 $ARGV
91 ),
92 );
93  
94 3 ▶use vars '@Arrays';
Subroutine BEGIN: called CC=1 SCAR=0.0
95 3 @Arrays = qw(
96 @+ $LAST_MATCH_END
97 @- @LAST_MATCH_START
98 @ARGV
99 @F
100 @INC
101 @_ @ARG
102 );
103  
104 3 ▶use vars '@Hashes';
Subroutine BEGIN: called CC=1 SCAR=0.0
105 3 @Hashes = qw(
106 %main
107 %CORE
108 %CORE::GLOBAL::
109 %OVERLOAD
110 %+ %LAST_MATCH_END
111 %- %LAST_MATCH_START
112 %! %OS_ERROR %ERRNO
113 %^H
114 %INC
115 %ENV
116 %SIG
117 );
118  
119 3 ▶use vars '@Filehandles';
Subroutine BEGIN: called CC=1 SCAR=0.0
120 3 @Filehandles = qw(
121 *ARGV ARGV
122 *_ _
123 ARGVOUT
124 DATA
125 STDIN
126 STDOUT
127 STDERR
128 );
129  
130 3 ▶use vars '@Functions';
Subroutine BEGIN: called CC=1 SCAR=0.0
131 3 ▶@Functions = (
Branch: 18 branches
BranchTrueFalseTotal
$] >= 5.015006 ? : 3 0 3
$] >= 5.005064 && $] < 5.006 ? : 0 3 3
$] >= 5.006 ? : 3 0 3
$] < 5.007003 ? : 0 3 3
$] >= 5.009005 ? : 3 0 3
$] >= 5.041007 ? : 3 0 3
$] >= 5.009003 && ($] < 5.027007 || $] >= 5.027008 || $CPERL) ? : 3 0 3
$] >= 5.009003 && ($] < 5.027007 || $CPERL) ? : 0 3 3
$] >= 5.015005 ? : 3 0 3
$] >= 5.029 && $CPERL ? : 0 3 3
$] >= 5.015008 ? : 3 0 3
$] >= 5.009003 ? : 3 0 3
$] >= 5.031007 ? : 3 0 3
$] >= 5.004 ? : 3 0 3
$] >= 5.005061 ? : 3 0 3
$] >= 5.009003 ? : 3 0 3
$] >= 5.009003 && ($] < 5.027007 || $] >= 5.027008 || $CPERL) ? : 3 0 3
$] >= 5.009003 && !$CPERL ? : 0 0 0
Condition30%10/33
$] >= "5.005064" and $] < "5.006"
!ll&&!rl&&r
030
$] >= "5.009003" and $] < "5.027007" || $] >= "5.027008" || $CPERL
!ll&&!rl&&r
003
$] < "5.027007" or $] >= "5.027008" or $CPERL
l!l&&r!l&&!r
300
$] < "5.027007" or $] >= "5.027008"
l!l&&r!l&&!r
030
$] >= "5.009003" and $] < "5.027007" || $CPERL
!ll&&!rl&&r
030
$] < "5.027007" or $CPERL
l!l&&r!l&&!r
003
$] >= "5.029" and $CPERL
!ll&&!rl&&r
030
$] >= "5.009003" and $] < "5.027007" || $] >= "5.027008" || $CPERL
!ll&&!rl&&r
003
$] < "5.027007" or $] >= "5.027008" or $CPERL
l!l&&r!l&&!r
300
$] < "5.027007" or $] >= "5.027008"
l!l&&r!l&&!r
030
$] >= "5.009003" and not $CPERL
!ll&&!rl&&r
000
MC/DC0%0/2
$] >= "5.005064" and $] < "5.006"
$] >= "5.005064" $] < "5.006"
MC/DC0%0/4
$] >= "5.009003" and $] < "5.027007" || $] >= "5.027008" || $CPERL
$] >= "5.009003" $] < "5.027007" $] >= "5.027008" $CPERL
MC/DC0%0/3
$] >= "5.009003" and $] < "5.027007" || $CPERL
$] >= "5.009003" $] < "5.027007" $CPERL
MC/DC0%0/2
$] >= "5.029" and $CPERL
$] >= "5.029" $CPERL
MC/DC0%0/4
$] >= "5.009003" and $] < "5.027007" || $] >= "5.027008" || $CPERL
$] >= "5.009003" $] < "5.027007" $] >= "5.027008" $CPERL
MC/DC0%0/2
$] >= "5.009003" and not $CPERL
$] >= "5.009003" not $CPERL
Truth table33%1/3
A and B
A= $] >= "5.005064"B= $] < "5.006"
ABresult
0X0
100
111
Truth table20%1/5
A and B or C or D
A= $] >= "5.009003"B= $] < "5.027007"C= $] >= "5.027008"D= $CPERL
ABCDresult
0XXX0
10000
11XX1
101X1
10011
Truth table25%1/4
A and B or C
A= $] >= "5.009003"B= $] < "5.027007"C= $CPERL
ABCresult
0XX0
1000
11X1
1011
Truth table33%1/3
A and B
A= $] >= "5.029"B= $CPERL
ABresult
0X0
100
111
Truth table20%1/5
A and B or C or D
A= $] >= "5.009003"B= $] < "5.027007"C= $] >= "5.027008"D= $CPERL
ABCDresult
0XXX0
10000
11XX1
101X1
10011
Truth table0%0/3
A and not(B)
A= $] >= "5.009003"B= not $CPERL
ABresult
0X0
100
111
132 ($] >= 5.015006 ? qw(
133 __SUB__
134 ) : ()), qw(
135 AUTOLOAD
136 BEGIN
137 DESTROY
138 END ),
139 # STOP was between 5.5.64 - 5.6.0
140 ($] >= 5.005064 && $] < 5.006
141 ? qw(STOP) : qw(CHECK)),
142 # INIT was called RESTART before 5.004_50
143 ($] >= 5.006
144 ? qw(INIT) : qw(RESTART)),
145 # removed with 855a8c432447
146 ($] < 5.007003 ? qw(
147 EQ GE GT LE LT NE
148 ) : ()),
149 ($] >= 5.009005 ? qw(
150 UNITCHECK
151 ) : ()), qw(
152 abs
153 accept ),
154 ($] >= 5.041007 ? qw(
155 any
156 all
157 ) : ()), qw(
158 alarm
159 atan2
160 bind
161 binmode
162 bless ),
163 ($] >= 5.009003 && ($] < 5.027007 || $] >= 5.027008 || $CPERL) ? qw(
164 break
165 ) : ()), qw(
166 caller
167 chdir
168 chmod
169 chomp
170 chop
171 chown
172 chr
173 chroot
174 close
175 closedir
176 connect
177 cos
178 crypt
179 dbmclose
180 dbmopen ),
181 ($] >= 5.009003 && ($] < 5.027007 || $CPERL) ? qw(
182 default
183 ) : ()), qw(
184 defined
185 delete
186 die
187 dump
188 each
189 endgrent
190 endhostent
191 endnetent
192 endprotoent
193 endpwent
194 endservent
195 eof
196 eval ),
197 ($] >= 5.015005 ? qw(
198 evalbytes
199 ) : ()), qw(
200 exec
201 exists
202 exit
203 exp ),
204 ($] >= 5.029 && $CPERL ? qw(
205 extern
206 ) : ()),
207 ($] >= 5.015008 ? qw(
208 fc
209 ) : ()), qw(
210 fcntl
211 fileno
212 flock
213 fork
214 format
215 formline
216 getc
217 getgrent
218 getgrgid
219 getgrnam
220 gethostbyaddr
221 gethostbyname
222 gethostent
223 getlogin
224 getnetbyaddr
225 getnetbyname
226 getnetent
227 getpeername
228 getpgrp
229 getppid
230 getpriority
231 getprotobyname
232 getprotobynumber
233 getprotoent
234 getpwent
235 getpwnam
236 getpwuid
237 getservbyname
238 getservbyport
239 getservent
240 getsockname
241 getsockopt ),
242 ($] >= 5.009003 ? qw(
243 given
244 ) : ()), qw(
245 glob
246 gmtime
247 goto
248 grep
249 hex
250 index
251 int
252 ioctl ),
253 ($] >= 5.031007 ? qw(
254 isa
255 ) : ()), qw(
256 join
257 keys
258 kill
259 last
260 lc
261 lcfirst
262 length
263 link
264 listen
265 local
266 localtime ),
267 ($] >= 5.004 ? qw(
268 lock
269 ) : ()), qw(
270 log
271 lstat
272 map
273 mkdir
274 msgctl
275 msgget
276 msgrcv
277 msgsnd
278 my
279 next
280 not
281 oct
282 open
283 opendir
284 ord ),
285 ($] >= 5.005061 ? qw(
286 our
287 ) : ()), qw(
288 pack
289 pipe
290 pop
291 pos
292 print
293 printf
294 prototype
295 push
296 quotemeta
297 rand
298 read
299 readdir
300 readline
301 readlink
302 readpipe
303 recv
304 redo
305 ref
306 rename
307 require
308 reset
309 return
310 reverse
311 rewinddir
312 rindex
313 rmdir ),
314 ($] >= 5.009003 ? qw(
315 say
316 ) : ()), qw(
317 scalar
318 seek
319 seekdir
320 select
321 semctl
322 semget
323 semop
324 send
325 setgrent
326 sethostent
327 setnetent
328 setpgrp
329 setpriority
330 setprotoent
331 setpwent
332 setservent
333 setsockopt
334 shift
335 shmctl
336 shmget
337 shmread
338 shmwrite
339 shutdown
340 sin
341 sleep
342 socket
343 socketpair
344 sort
345 splice
346 split
347 sprintf
348 sqrt
349 srand
350 stat
351 study
352 substr
353 symlink
354 syscall
355 sysopen
356 sysread
357 sysseek
358 system
359 syswrite
360 tell
361 telldir
362 tie
363 tied
364 time
365 times
366 truncate
367 uc
368 ucfirst
369 umask
370 undef
371 unlink
372 unpack
373 unshift
374 untie
375 use
376 utime
377 values
378 vec
379 wait
380 waitpid
381 wantarray
382 warn ),
383 ($] >= 5.009003 && ($] < 5.027007 || $] >= 5.027008 || $CPERL) ? qw(
384 when
385 ) : ($] >= 5.009003 && !$CPERL) ? qw(
386 whereis
387 whereso
388 ) : ()), qw(
389 write
390  
391 -r -w -x -o
392 -R -W -X -O -e -z -s
393 -f -d -l -p -S -b -c -t
394 -u -g -k
395 -T -B
396 -M -A -C
397 ));
398  
399 3 ▶use vars '@Barewords';
Subroutine BEGIN: called CC=1 SCAR=0.0
400 3 ▶@Barewords = (
Branch: 13 branches
BranchTrueFalseTotal
$] >= 5.0 && $] < 5.01901 ? : 0 3 3
$CPERL && $] >= 5.027001 ? : 0 3 3
$] >= 5.008001 && $] < 5.01 ? : 0 3 3
$] >= 5.004072 ? : 3 0 3
$] == 5.007003 ? : 0 3 3
$] >= 5.009003 ? : 3 0 3
$] >= 5.009003 && ($] < 5.027007 || $] >= 5.027008) ? : 3 0 3
$] >= 5.009004 ? : 3 0 3
$] >= 5.033007 ? : 3 0 3
$] >= 5.035004 ? : 3 0 3
$] >= 5.035008 ? : 3 0 3
$] >= 5.038 ? : 3 0 3
$] >= 5.039002 ? : 3 0 3
Condition33%5/15
$] >= 5 and $] < "5.01901"
!ll&&!rl&&r
030
$CPERL and $] >= "5.027001"
!ll&&!rl&&r
300
$] >= "5.008001" and $] < "5.01"
!ll&&!rl&&r
030
$] >= "5.009003" and $] < "5.027007" || $] >= "5.027008"
!ll&&!rl&&r
003
$] < "5.027007" or $] >= "5.027008"
l!l&&r!l&&!r
030
MC/DC0%0/2
$] >= 5 and $] < "5.01901"
$] >= 5 $] < "5.01901"
MC/DC0%0/2
$CPERL and $] >= "5.027001"
$CPERL $] >= "5.027001"
MC/DC0%0/2
$] >= "5.008001" and $] < "5.01"
$] >= "5.008001" $] < "5.01"
MC/DC0%0/3
$] >= "5.009003" and $] < "5.027007" || $] >= "5.027008"
$] >= "5.009003" $] < "5.027007" $] >= "5.027008"
Truth table33%1/3
A and B
A= $] >= 5B= $] < "5.01901"
ABresult
0X0
100
111
Truth table33%1/3
A and B
A= $CPERLB= $] >= "5.027001"
ABresult
0X0
100
111
Truth table33%1/3
A and B
A= $] >= "5.008001"B= $] < "5.01"
ABresult
0X0
100
111
Truth table25%1/4
A and B or C
A= $] >= "5.009003"B= $] < "5.027007"C= $] >= "5.027008"
ABCresult
0XX0
1000
11X1
1011
401 qw(
402 __FILE__
403 __LINE__
404 __PACKAGE__
405 __DATA__
406 __END__
407 NULL
408 and ),
409 #removed with a96df643850d22bc4a94
410 ($] >= 5.000 && $] < 5.019010 ? qw(
411 CORE
412 ) : ()),
413 ($CPERL && $] >= 5.027001 ? qw(
414 class method role multi has
415 ) : ()), qw(
416 cmp
417 continue
418 do
419 else
420 elsif
421 eq ),
422 # added with dor (c963b151157d), removed with f23102e2d6356
423 # in fact this was never in keywords.h for some reason
424 ($] >= 5.008001 && $] < 5.010 ? qw(
425 err
426 ) : ()),
427 qw(
428 for
429 foreach
430 ge
431 gt
432 if
433 le
434 lock
435 lt
436 m
437 ne
438 no
439 or
440 package
441 q
442 qq ),
443 ($] >= 5.004072 ? qw(
444 qr
445 ) : ()),
446 ($] == 5.007003 ? qw(
447 qu
448 ) : ()), qw(
449 qw
450 qx
451 s
452 sub
453 tr
454 unless
455 until
456 while
457 x
458 xor
459 y
460 ),
461 # also with default, say
462 ($] >= 5.009003 ? qw(
463 break
464 given
465 when
466 ) : ()
467 ),
468 # removed as useless with 5.27.7, re-added with 7896dde7482a2851
469 ($] >= 5.009003 && ($] < 5.027007 || $] >= 5.027008) ? qw(
470 default
471 ) : ()
472 ),
473 ($] >= 5.009004 ? qw(
474 state
475 ) : ()
476 ),
477 ($] >= 5.033007 ? qw(
478 try
479 catch
480 ) : ()
481 ),
482 ($] >= 5.035004 ? qw(
483 defer
484 ) : ()
485 ),
486 ($] >= 5.035008 ? qw(
487 finally
488 ) : ()
489 ),
490 ($] >= 5.038000 ? qw(
491 ADJUST
492 class
493 field
494 method
495 ) : ()
496 ),
497 ($] >= 5.039002 ? qw{
498 __CLASS__
499 } : ()
500 ),
501 );
502  
503 # Extra barewords not in keywords.h (import was never in keywords)
504 3 ▶use vars '@BarewordsExtra';
Subroutine BEGIN: called CC=1 SCAR=0.0
505 3 @BarewordsExtra = qw(
506 import
507 unimport
508 );
509  
510 3 ▶use vars '@TieIOMethods';
Subroutine BEGIN: called CC=1 SCAR=0.0
511 3 @TieIOMethods = qw(
512 BINMODE CLEAR CLEARERR CLONE CLONE_SKIP CLOSE DELETE EOF
513 ERROR EXISTS EXTEND FDOPEN FETCH FETCHSIZE FILENO FILL FIRSTKEY FLUSH
514 GETC NEXTKEY OPEN POP POPPED PRINT PRINTF PUSH PUSHED READ READLINE
515 SCALAR SEEK SETLINEBUF SHIFT SPLICE STORE STORESIZE SYSOPEN TELL
516 TIEARRAY TIEHANDLE TIEHASH TIESCALAR UNREAD UNSHIFT UNTIE UTF8 WRITE
517 );
518  
519 3 ▶use vars '@UNIVERSALMethods';
Subroutine BEGIN: called CC=1 SCAR=0.0
520 3 @UNIVERSALMethods = qw(
521 can isa DOES VERSION
522 );
523  
524 3 ▶use vars '@ExporterSymbols';
Subroutine BEGIN: called CC=1 SCAR=0.0
525 3 @ExporterSymbols = qw(
526 @EXPORT @EXPORT_OK @EXPORT_FAIL
527 @EXPORT_TAGS _push_tags _rebuild_cache as_heavy export export_fail
528 export_fail_in export_ok_tags export_tags export_to_level heavy_export
529 heavy_export_ok_tags heavy_export_tags heavy_export_to_level
530 heavy_require_version require_version
531 );
532  
533 3 ▶use vars '@Symbols';
Subroutine BEGIN: called CC=1 SCAR=0.0
534 3 @Symbols = ( @Scalars, @Arrays, @Hashes, @Filehandles, @Functions );
535  
536 # This quote is blatantly copied from ErrantStory.com, Michael Poe's
537 # comic.
538 3 ▶BEGIN { $^W = 0 }
Subroutine BEGIN: called CC=1 SCAR=0.0
539 3 "You know, when you stop and think about it, Cthulhu is a bit a Mary Sue isn't he?"
540  
541 __END__
↑ Summary