line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
9
|
|
|
9
|
|
53
|
use warnings; |
|
9
|
|
|
|
|
18
|
|
|
9
|
|
|
|
|
346
|
|
2
|
9
|
|
|
9
|
|
46
|
use strict; |
|
9
|
|
|
|
|
19
|
|
|
9
|
|
|
|
|
427
|
|
3
|
|
|
|
|
|
|
|
4
|
|
|
|
|
|
|
=head1 NAME |
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
Data::SExpression::Cons -- Representation of a Lisp cons read by |
7
|
|
|
|
|
|
|
Data::SExpression. |
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
=head1 DESCRIPTION |
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
=cut |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
package Data::SExpression::Cons; |
14
|
9
|
|
|
9
|
|
57
|
use base qw(Class::Accessor::Fast); |
|
9
|
|
|
|
|
15
|
|
|
9
|
|
|
|
|
2573
|
|
15
|
|
|
|
|
|
|
__PACKAGE__->mk_accessors(qw(car cdr)); |
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
=head2 new CAR CDR |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
Construct a new C with the given C and C |
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
=cut |
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
sub new { |
24
|
116
|
|
|
116
|
1
|
134
|
my $class = shift; |
25
|
116
|
|
|
|
|
136
|
my ($car, $cdr) = @_; |
26
|
|
|
|
|
|
|
|
27
|
116
|
|
|
|
|
333
|
my $self = {car => $car, cdr => $cdr}; |
28
|
116
|
|
|
|
|
481
|
return bless($self, $class); |
29
|
|
|
|
|
|
|
} |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
=head2 car, cdr |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
Returns the C or C of this C. |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
=head2 set_car CAR, set_cdr CDR |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
Set the C or C of this C object. |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
=cut |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
sub mutator_name_for { |
42
|
18
|
|
|
18
|
1
|
873
|
my $self = shift; |
43
|
18
|
|
|
|
|
29
|
my $name = shift; |
44
|
18
|
|
|
|
|
57
|
return "set_$name"; |
45
|
|
|
|
|
|
|
} |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
=head1 SEE ALSO |
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
L |
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
=head1 AUTHOR |
52
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
Nelson Elhage |
54
|
|
|
|
|
|
|
|
55
|
|
|
|
|
|
|
=cut |
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
1; |