| line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
|
1
|
|
|
|
|
|
|
# -*- coding: utf-8 -*- |
|
2
|
|
|
|
|
|
|
# Copyright (C) 2011-2014 Rocky Bernstein <rocky@cpan.org> |
|
3
|
12
|
|
|
12
|
|
609
|
use warnings; no warnings 'redefine'; |
|
|
12
|
|
|
12
|
|
28
|
|
|
|
12
|
|
|
2
|
|
494
|
|
|
|
12
|
|
|
2
|
|
66
|
|
|
|
12
|
|
|
|
|
27
|
|
|
|
12
|
|
|
|
|
592
|
|
|
|
2
|
|
|
|
|
15
|
|
|
|
2
|
|
|
|
|
6
|
|
|
|
2
|
|
|
|
|
101
|
|
|
|
2
|
|
|
|
|
11
|
|
|
|
2
|
|
|
|
|
3
|
|
|
|
2
|
|
|
|
|
96
|
|
|
4
|
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
package Devel::Trepan::CmdProcessor::Command::Set; |
|
6
|
|
|
|
|
|
|
|
|
7
|
12
|
|
|
12
|
|
65
|
use rlib '../../../..'; |
|
|
12
|
|
|
2
|
|
55
|
|
|
|
12
|
|
|
|
|
76
|
|
|
|
2
|
|
|
|
|
10
|
|
|
|
2
|
|
|
|
|
4
|
|
|
|
2
|
|
|
|
|
11
|
|
|
8
|
12
|
|
|
12
|
|
5349
|
use if !@ISA, Devel::Trepan::CmdProcessor::Command::Subcmd::SubMgr; |
|
|
12
|
|
|
2
|
|
25
|
|
|
|
12
|
|
|
|
|
66
|
|
|
|
2
|
|
|
|
|
822
|
|
|
|
2
|
|
|
|
|
5
|
|
|
|
2
|
|
|
|
|
10
|
|
|
9
|
|
|
|
|
|
|
unless (@ISA) { |
|
10
|
12
|
|
|
12
|
|
77
|
eval <<'EOE'; |
|
|
12
|
|
|
12
|
|
37
|
|
|
|
12
|
|
|
12
|
|
703
|
|
|
|
12
|
|
|
12
|
|
75
|
|
|
|
12
|
|
|
12
|
|
27
|
|
|
|
12
|
|
|
|
|
547
|
|
|
|
12
|
|
|
|
|
73
|
|
|
|
12
|
|
|
|
|
31
|
|
|
|
12
|
|
|
|
|
604
|
|
|
|
12
|
|
|
|
|
67
|
|
|
|
12
|
|
|
|
|
32
|
|
|
|
12
|
|
|
|
|
635
|
|
|
|
12
|
|
|
|
|
70
|
|
|
|
12
|
|
|
|
|
29
|
|
|
|
12
|
|
|
|
|
574
|
|
|
11
|
|
|
|
|
|
|
use constant CATEGORY => 'support'; |
|
12
|
|
|
|
|
|
|
use constant SHORT_HELP => 'Modify parts of the debugger environment'; |
|
13
|
|
|
|
|
|
|
use constant MIN_ARGS => 0; # Need at least this many |
|
14
|
|
|
|
|
|
|
use constant MAX_ARGS => undef; # Need at most this many - |
|
15
|
|
|
|
|
|
|
# undef -> unlimited. |
|
16
|
|
|
|
|
|
|
use constant NEED_STACK => 0; |
|
17
|
|
|
|
|
|
|
EOE |
|
18
|
|
|
|
|
|
|
} |
|
19
|
|
|
|
|
|
|
|
|
20
|
12
|
|
|
12
|
|
4113
|
use if !@ISA, Devel::Trepan::CmdProcessor::Command; |
|
|
12
|
|
|
2
|
|
24
|
|
|
|
12
|
|
|
|
|
52
|
|
|
|
2
|
|
|
|
|
109
|
|
|
|
2
|
|
|
|
|
3
|
|
|
|
2
|
|
|
|
|
8
|
|
|
21
|
12
|
|
|
12
|
|
1702
|
use strict; |
|
|
12
|
|
|
2
|
|
29
|
|
|
|
12
|
|
|
|
|
304
|
|
|
|
2
|
|
|
|
|
61
|
|
|
|
2
|
|
|
|
|
4
|
|
|
|
2
|
|
|
|
|
40
|
|
|
22
|
12
|
|
|
12
|
|
55
|
use vars qw(@ISA); |
|
|
12
|
|
|
2
|
|
26
|
|
|
|
12
|
|
|
|
|
736
|
|
|
|
2
|
|
|
|
|
15
|
|
|
|
2
|
|
|
|
|
5
|
|
|
|
2
|
|
|
|
|
115
|
|
|
23
|
|
|
|
|
|
|
@ISA = qw(Devel::Trepan::CmdProcessor::Command::SubcmdMgr); |
|
24
|
12
|
|
|
12
|
|
72
|
use vars @CMD_VARS; |
|
|
12
|
|
|
2
|
|
30
|
|
|
|
12
|
|
|
|
|
3909
|
|
|
|
2
|
|
|
|
|
10
|
|
|
|
2
|
|
|
|
|
4
|
|
|
|
2
|
|
|
|
|
606
|
|
|
25
|
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
our $NAME = set_name(); |
|
27
|
|
|
|
|
|
|
=pod |
|
28
|
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
=head2 Synopsis: |
|
30
|
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
=cut |
|
32
|
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
our $HELP = <<'HELP'; |
|
34
|
|
|
|
|
|
|
=pod |
|
35
|
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
B<set> [I<set sub-commmand> ...] |
|
37
|
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
Modifies parts of the debugger environment. |
|
39
|
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
You can give unique prefix of the name of a subcommand to get |
|
41
|
|
|
|
|
|
|
information about just that subcommand. |
|
42
|
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
Type C<set> for a list of set subcommands and what they do. |
|
44
|
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
Type C<help set *> for the list of C<set> subcommands. |
|
46
|
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
C<set auto...> is the same as C<set auto ...>. For example, C<set |
|
48
|
|
|
|
|
|
|
autolist> is the same as L<C<set auto |
|
49
|
|
|
|
|
|
|
list>|Devel::Trepan::CmdProcessor::Command::Set::Auto::List>. |
|
50
|
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
=head2 See also: |
|
52
|
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
L<C<set abbrev>|Devel::Trepan::CmdProcessor::Command::Set::Abbrev>, |
|
54
|
|
|
|
|
|
|
L<C<set auto>|Devel::Trepan::CmdProcessor::Command::Set::Auto>, |
|
55
|
|
|
|
|
|
|
L<C<set basename>|Devel::Trepan::CmdProcessor::Command::Set::Basename>, |
|
56
|
|
|
|
|
|
|
L<C<set confirm>|Devel::Trepan::CmdProcessor::Command::Set::Confirm>, |
|
57
|
|
|
|
|
|
|
L<C<set debug>|Devel::Trepan::CmdProcessor::Command::Set::Debug>, |
|
58
|
|
|
|
|
|
|
L<C<set different>|Devel::Trepan::CmdProcessor::Command::Set::Different>, |
|
59
|
|
|
|
|
|
|
L<C<set display>|Devel::Trepan::CmdProcessor::Command::Set::Display>, |
|
60
|
|
|
|
|
|
|
L<C<set highlight>|Devel::Trepan::CmdProcessor::Command::Set::Highlight>, |
|
61
|
|
|
|
|
|
|
L<C<set max>|Devel::Trepan::CmdProcessor::Command::Set::Max>, |
|
62
|
|
|
|
|
|
|
L<C<set return>|Devel::Trepan::CmdProcessor::Command::Set::Return>, |
|
63
|
|
|
|
|
|
|
L<C<set substitute>|Devel::Trepan::CmdProcessor::Command::Set::Substitute>, |
|
64
|
|
|
|
|
|
|
L<C<set timer>|Devel::Trepan::CmdProcessor::Command::Set::Timer>, |
|
65
|
|
|
|
|
|
|
L<C<set trace>|Devel::Trepan::CmdProcessor::Command::Set::Trace>, and |
|
66
|
|
|
|
|
|
|
L<C<set variable>|Devel::Trepan::CmdProcessor::Command::Set::Variable> |
|
67
|
|
|
|
|
|
|
=cut |
|
68
|
|
|
|
|
|
|
HELP |
|
69
|
|
|
|
|
|
|
|
|
70
|
|
|
|
|
|
|
sub run($$) |
|
71
|
|
|
|
|
|
|
{ |
|
72
|
0
|
|
|
0
|
0
|
|
my ($self, $args) = @_; |
|
|
0
|
|
|
0
|
0
|
|
|
|
73
|
0
|
|
|
|
|
|
my $first; |
|
|
0
|
|
|
|
|
|
|
|
74
|
0
|
0
|
|
|
|
|
if (scalar @$args > 1) { |
|
|
0
|
0
|
|
|
|
|
|
|
75
|
0
|
|
|
|
|
|
$first = lc $args->[1]; |
|
|
0
|
|
|
|
|
|
|
|
76
|
0
|
|
|
|
|
|
my $alen = length('auto'); |
|
|
0
|
|
|
|
|
|
|
|
77
|
0
|
0
|
0
|
|
|
|
splice(@$args, 1, 1, ('auto', substr($first, $alen))) if |
|
|
0
|
0
|
0
|
|
|
|
|
|
78
|
|
|
|
|
|
|
index($first, 'auto') == 0 && length($first) > $alen; |
|
79
|
|
|
|
|
|
|
} |
|
80
|
0
|
|
|
|
|
|
$self->SUPER::run($args); |
|
|
0
|
|
|
|
|
|
|
|
81
|
|
|
|
|
|
|
} |
|
82
|
|
|
|
|
|
|
|
|
83
|
|
|
|
|
|
|
unless (caller) { |
|
84
|
|
|
|
|
|
|
require Devel::Trepan::CmdProcessor; |
|
85
|
|
|
|
|
|
|
my $proc = Devel::Trepan::CmdProcessor->new(undef, 'bogus'); |
|
86
|
|
|
|
|
|
|
my $cmd = __PACKAGE__->new($proc, $NAME); |
|
87
|
|
|
|
|
|
|
# require_relative '../mock' |
|
88
|
|
|
|
|
|
|
$cmd->run([$NAME]); |
|
89
|
|
|
|
|
|
|
# $cmd->run([$NAME, 'autolist']); |
|
90
|
|
|
|
|
|
|
# $cmd->run([$NAME, 'autoeval', 'off']); |
|
91
|
|
|
|
|
|
|
$cmd->run([$NAME, 'basename']); |
|
92
|
|
|
|
|
|
|
} |
|
93
|
|
|
|
|
|
|
|
|
94
|
|
|
|
|
|
|
1; |