blib/lib/Regexp/Extended/Match.pm | |||
---|---|---|---|
Criterion | Covered | Total | % |
statement | 6 | 11 | 54.5 |
branch | n/a | ||
condition | 0 | 3 | 0.0 |
subroutine | 2 | 3 | 66.6 |
pod | 0 | 1 | 0.0 |
total | 8 | 18 | 44.4 |
line | stmt | bran | cond | sub | pod | time | code |
---|---|---|---|---|---|---|---|
1 | package Regexp::Extended::Match; | ||||||
2 | |||||||
3 | 2 | 2 | 10 | use strict; | |||
2 | 5 | ||||||
2 | 78 | ||||||
4 | 2 | 2 | 12 | use Carp; | |||
2 | 4 | ||||||
2 | 337 | ||||||
5 | |||||||
6 | sub new { | ||||||
7 | 0 | 0 | 0 | my ($this, $name, $value, $pos) = @_; | |||
8 | 0 | 0 | my $class = ref($this) || $this; | ||||
9 | 0 | my $self = { | |||||
10 | 'name' => $name, | ||||||
11 | 'value' => $value, | ||||||
12 | 'end' => $pos, | ||||||
13 | 'start' => undef, | ||||||
14 | 'length' => undef, | ||||||
15 | 'childs' => undef, | ||||||
16 | 'parent' => undef, | ||||||
17 | 'dirty' => 0, | ||||||
18 | }; | ||||||
19 | 0 | bless $self, $class; | |||||
20 | 0 | return $self; | |||||
21 | } | ||||||
22 | |||||||
23 | return 1; |