| line | stmt | bran | cond | sub | pod | time | code | 
| 1 | 1 |  |  | 1 |  | 692 | use strict; use warnings; | 
|  | 1 |  |  | 1 |  | 2 |  | 
|  | 1 |  |  |  |  | 24 |  | 
|  | 1 |  |  |  |  | 4 |  | 
|  | 1 |  |  |  |  | 1 |  | 
|  | 1 |  |  |  |  | 26 |  | 
| 2 |  |  |  |  |  |  | package Inline::C::Parser::Pegex; | 
| 3 |  |  |  |  |  |  |  | 
| 4 | 1 |  |  | 1 |  | 389 | use Pegex::Parser; | 
|  | 1 |  |  |  |  | 10432 |  | 
|  | 1 |  |  |  |  | 24 |  | 
| 5 | 1 |  |  | 1 |  | 368 | use Inline::C::Parser::Pegex::Grammar; | 
|  | 1 |  |  |  |  | 2 |  | 
|  | 1 |  |  |  |  | 7 |  | 
| 6 | 1 |  |  | 1 |  | 354 | use Inline::C::Parser::Pegex::AST; | 
|  | 1 |  |  |  |  | 2 |  | 
|  | 1 |  |  |  |  | 140 |  | 
| 7 |  |  |  |  |  |  |  | 
| 8 |  |  |  |  |  |  | sub register { | 
| 9 |  |  |  |  |  |  | { | 
| 10 | 0 |  |  | 0 | 0 |  | extends => [qw(C)], | 
| 11 |  |  |  |  |  |  | overrides => [qw(get_parser)], | 
| 12 |  |  |  |  |  |  | } | 
| 13 |  |  |  |  |  |  | } | 
| 14 |  |  |  |  |  |  |  | 
| 15 |  |  |  |  |  |  | sub get_parser { | 
| 16 | 0 |  |  | 0 | 0 |  | my $o = shift; | 
| 17 | 0 | 0 |  |  |  |  | Inline::C::_parser_test($o->{CONFIG}{DIRECTORY}, "Inline::C::Parser::Pegex::get_parser called\n") if $o->{CONFIG}{_TESTING}; | 
| 18 | 0 |  |  |  |  |  | bless {}, 'Inline::C::Parser::Pegex' | 
| 19 |  |  |  |  |  |  | } | 
| 20 |  |  |  |  |  |  |  | 
| 21 |  |  |  |  |  |  | sub code { | 
| 22 | 0 |  |  | 0 | 0 |  | my($self,$code) = @_; | 
| 23 |  |  |  |  |  |  |  | 
| 24 |  |  |  |  |  |  | $main::data = $self->{data} = | 
| 25 | 0 |  |  |  |  |  | Pegex::Parser->new( | 
| 26 |  |  |  |  |  |  | grammar => Inline::C::Parser::Pegex::Grammar->new, | 
| 27 |  |  |  |  |  |  | receiver => Inline::C::Parser::Pegex::AST->new, | 
| 28 |  |  |  |  |  |  | # debug => 1, | 
| 29 |  |  |  |  |  |  | )->parse($code); | 
| 30 |  |  |  |  |  |  |  | 
| 31 | 0 |  |  |  |  |  | return 1; | 
| 32 |  |  |  |  |  |  | } | 
| 33 |  |  |  |  |  |  |  | 
| 34 |  |  |  |  |  |  | 1; |