File Coverage

blib/lib/Regexp/Parser/Diagnostics.pm
Criterion Covered Total %
statement 91 91 100.0
branch n/a
condition n/a
subroutine 31 31 100.0
pod n/a
total 122 122 100.0


line stmt bran cond sub pod time code
1             package Regexp::Parser;
2              
3 8     8   59 use strict;
  8         60  
  8         285  
4 8     8   50 use warnings;
  8         18  
  8         352  
5              
6             my $ENUM;
7 8     8   242 BEGIN { $ENUM = 0 }
8              
9 8     8   49 use constant RPe_ZQUANT => --$ENUM, 'Quantifier unexpected on zero-length expression';
  8         18  
  8         818  
10 8     8   54 use constant RPe_NOTIMP => --$ENUM, 'Sequence (?%.*s...) not implemented';
  8         18  
  8         438  
11 8     8   56 use constant RPe_NOTERM => --$ENUM, 'Sequence (?#... not terminated';
  8         21  
  8         437  
12 8     8   48 use constant RPe_LOGDEP => --$ENUM, '(?p{}) is deprecated -- use (??{})';
  8         19  
  8         433  
13 8     8   48 use constant RPe_NOTBAL => --$ENUM, 'Sequence (?{...}) not terminated or not {}-balanced';
  8         18  
  8         424  
14 8     8   46 use constant RPe_SWNREC => --$ENUM, 'Switch condition not recognized';
  8         17  
  8         416  
15 8     8   49 use constant RPe_SWBRAN => --$ENUM, 'Switch (?(condition)... contains too many branches';
  8         16  
  8         417  
16 8     8   50 use constant RPe_SWUNKN => --$ENUM, 'Unknown switch condition (?(%.2s';
  8         15  
  8         450  
17 8     8   49 use constant RPe_SEQINC => --$ENUM, 'Sequence (? incomplete';
  8         23  
  8         951  
18 8     8   45 use constant RPe_BADFLG => --$ENUM, 'Useless (?%s%s) -- %suse /%s modifier';
  8         16  
  8         395  
19 8     8   49 use constant RPe_NOTREC => --$ENUM, 'Sequence (?%.*s...) not recognized';
  8         18  
  8         427  
20 8     8   46 use constant RPe_LPAREN => --$ENUM, 'Unmatched (';
  8         17  
  8         388  
21 8     8   43 use constant RPe_RPAREN => --$ENUM, 'Unmatched )';
  8         21  
  8         404  
22 8     8   46 use constant RPe_BCURLY => --$ENUM, 'Can\'t do {n,m} with n > m';
  8         17  
  8         383  
23 8     8   45 use constant RPe_NULNUL => --$ENUM, '%s matches null string many times';
  8         15  
  8         387  
24 8     8   42 use constant RPe_NESTED => --$ENUM, 'Nested quantifiers';
  8         19  
  8         421  
25 8     8   52 use constant RPe_LBRACK => --$ENUM, 'Unmatched [';
  8         18  
  8         412  
26 8     8   45 use constant RPe_EQUANT => --$ENUM, 'Quantifier follows nothing';
  8         19  
  8         376  
27 8     8   42 use constant RPe_BRACES => --$ENUM, 'Missing braces on \%s{}';
  8         19  
  8         363  
28 8     8   45 use constant RPe_RBRACE => --$ENUM, 'Missing right brace on \%s{}';
  8         61  
  8         407  
29 8     8   53 use constant RPe_BGROUP => --$ENUM, 'Reference to nonexistent group';
  8         16  
  8         425  
30 8     8   53 use constant RPe_ESLASH => --$ENUM, 'Trailing \\';
  8         16  
  8         401  
31 8     8   43 use constant RPe_BADESC => --$ENUM, 'Unrecognized escape \\%s%s passed through';
  8         16  
  8         365  
32 8     8   43 use constant RPe_BADPOS => --$ENUM, 'POSIX class [:%s:] unknown';
  8         21  
  8         383  
33 8     8   53 use constant RPe_OUTPOS => --$ENUM, 'POSIX syntax [%s %s] belongs inside character classes';
  8         19  
  8         436  
34 8     8   46 use constant RPe_EMPTYB => --$ENUM, 'Empty \%s{}';
  8         17  
  8         407  
35 8     8   51 use constant RPe_FRANGE => --$ENUM, 'False [] range "%s-%s"';
  8         16  
  8         441  
36 8     8   47 use constant RPe_IRANGE => --$ENUM, 'Invalid [] range "%s-%s"';
  8         16  
  8         390  
37              
38             1;