Tool/EnglishMorpho/exceptions/nouns_plural_es.pl untested

filter: Statementstmt 0.0% 0 / 13 Branchbran 0.0% 0 / 6 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 2 Podpod 0.0% 0 / 2 totaltotal 0.0% 0 / 23 CC 1 SCAR 6.9
CC
1
Cov
0%
analyze
2.0
generate
2.0
CRAP 2.0
1 #!/usr/bin/env perl
2 my @DATA = qw(
3 bias
4 canvas
5 gas
6 iris
7 );
8  
9 sub analyze() { ## no critic qw(Subroutines::ProhibitSubroutinePrototypes)
10 foreach (@DATA) {
11 print "${_}es\tNNS\t$_\n";
12 }
13 return;
14 }
15  
16 sub generate() { ## no critic qw(Subroutines::ProhibitSubroutinePrototypes)
17 foreach (@DATA) {
18 print "$_\t${_}es\n";
19 }
20 return;
21 }
22  
23 if ( $ARGV[0] eq '-a' ) { analyze(); }
24 elsif ( $ARGV[0] eq '-g' ) { generate(); }
25 elsif ( $ARGV[0] eq '-d' ) {
26 foreach (@DATA) { print "$_\n"; }
27 }
28 else { die "Invalid usage: use option -a, -g or -d\n"; }