line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
# $Header: /home/fergal/my/cvs/Code-Perl/lib/Code/Perl/Expr/Perl.pm,v 1.1 2003/06/17 14:14:21 fergal Exp $ |
2
|
|
|
|
|
|
|
|
3
|
1
|
|
|
1
|
|
5
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
43
|
|
4
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
package Code::Perl::Expr::Perl; |
6
|
|
|
|
|
|
|
|
7
|
1
|
|
|
1
|
|
4
|
use base 'Code::Perl::Expr::Base'; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
70
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
use Class::MethodMaker ( |
10
|
1
|
|
|
|
|
6
|
get_set => [qw( -java Perl )] |
11
|
1
|
|
|
1
|
|
4
|
); |
|
1
|
|
|
|
|
2
|
|
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
sub eval |
14
|
|
|
|
|
|
|
{ |
15
|
2
|
|
|
2
|
0
|
16
|
my $self = shift; |
16
|
|
|
|
|
|
|
|
17
|
2
|
|
|
|
|
69
|
my $perl = $self->getPerl; |
18
|
|
|
|
|
|
|
|
19
|
2
|
50
|
|
|
|
27
|
if (wantarray) |
20
|
|
|
|
|
|
|
{ |
21
|
0
|
|
|
|
|
0
|
my @value = eval $perl; |
22
|
|
|
|
|
|
|
|
23
|
0
|
0
|
|
|
|
0
|
die $@ if $@; |
24
|
|
|
|
|
|
|
|
25
|
0
|
|
|
|
|
0
|
return @value; |
26
|
|
|
|
|
|
|
} |
27
|
|
|
|
|
|
|
else |
28
|
|
|
|
|
|
|
{ |
29
|
2
|
|
|
|
|
109
|
my $value = eval $perl; |
30
|
|
|
|
|
|
|
|
31
|
2
|
50
|
|
|
|
10
|
die $@ if $@; |
32
|
|
|
|
|
|
|
|
33
|
2
|
|
|
|
|
10
|
return $value; |
34
|
|
|
|
|
|
|
} |
35
|
|
|
|
|
|
|
} |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
sub perl |
38
|
|
|
|
|
|
|
{ |
39
|
2
|
|
|
2
|
0
|
29
|
my $self = shift; |
40
|
|
|
|
|
|
|
|
41
|
2
|
|
|
|
|
74
|
return $self->getPerl; |
42
|
|
|
|
|
|
|
} |
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
1; |