line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
11
|
|
|
11
|
|
17158
|
use 5.006; |
|
11
|
|
|
|
|
24
|
|
2
|
11
|
|
|
11
|
|
38
|
use strict; |
|
11
|
|
|
|
|
11
|
|
|
11
|
|
|
|
|
180
|
|
3
|
11
|
|
|
11
|
|
34
|
use warnings; |
|
11
|
|
|
|
|
9
|
|
|
11
|
|
|
|
|
477
|
|
4
|
|
|
|
|
|
|
package Getopt::Lucid::Exception; |
5
|
|
|
|
|
|
|
# ABSTRACT: Exception classes for Getopt::Lucid |
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
our $VERSION = '1.08'; |
8
|
|
|
|
|
|
|
|
9
|
11
|
|
|
11
|
|
36
|
use Exporter; |
|
11
|
|
|
|
|
11
|
|
|
11
|
|
|
|
|
968
|
|
10
|
|
|
|
|
|
|
our @ISA = qw/Exporter Exception::Class::Base/; |
11
|
|
|
|
|
|
|
our @EXPORT = qw( throw_spec throw_argv throw_usage); |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
use Exception::Class 1.23 ( |
14
|
11
|
|
|
|
|
84
|
"Getopt::Lucid::Exception" => { |
15
|
|
|
|
|
|
|
description => "Unidentified exception", |
16
|
|
|
|
|
|
|
}, |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
"Getopt::Lucid::Exception::Spec" => { |
19
|
|
|
|
|
|
|
description => "Invalid specification", |
20
|
|
|
|
|
|
|
}, |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
"Getopt::Lucid::Exception::ARGV" => { |
23
|
|
|
|
|
|
|
description => "Invalid argument on command line", |
24
|
|
|
|
|
|
|
}, |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
"Getopt::Lucid::Exception::Usage" => { |
27
|
|
|
|
|
|
|
description => "Invalid usage", |
28
|
|
|
|
|
|
|
}, |
29
|
|
|
|
|
|
|
|
30
|
11
|
|
|
11
|
|
446
|
); |
|
11
|
|
|
|
|
8319
|
|
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
my %throwers = ( |
33
|
|
|
|
|
|
|
throw_spec => "Getopt::Lucid::Exception::Spec", |
34
|
|
|
|
|
|
|
throw_argv => "Getopt::Lucid::Exception::ARGV", |
35
|
|
|
|
|
|
|
throw_usage => "Getopt::Lucid::Exception::Usage", |
36
|
|
|
|
|
|
|
); |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
for my $t ( keys %throwers ) { |
39
|
11
|
|
|
11
|
|
7863
|
no strict 'refs'; |
|
11
|
|
|
|
|
13
|
|
|
11
|
|
|
|
|
762
|
|
40
|
69
|
|
|
69
|
|
364
|
*{$t} = sub { $throwers{$t}->throw("$_[0]\n") }; |
41
|
|
|
|
|
|
|
} |
42
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
1; |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
__END__ |