Branch Coverage

Parser.xs
Criterion Covered Total %
branch 108 132 81.8


line true false branch
41 1 513 SvGETMAGIC(h);
0 1 SvGETMAGIC(h);
42 288 226 if (SvROK(h)) {
44 162 126 if (SvTYPE(myref) == SVt_PVCV)
46 125 1 if (SvTYPE(myref) == SVt_PVAV)
50 224 2 return SvOK(h) ? newSVsv(h) : 0;
58 8130 1 MAGIC *mg = SvMAGICAL(sv) ? mg_find(sv, '~') : NULL;
60 1 8130 if (!mg)
63 0 8130 if (!p)
65 0 8130 if (p->signature != P_SIGNATURE)
78 8133 0 if (!sv || SvTYPE(sv) != SVt_PVHV)
0 8133 if (!sv || SvTYPE(sv) != SVt_PVHV)
82 8132 1 if (svp) {
83 8131 1 if (SvROK(*svp))
104 1161 129 for (i = 0; i < EVENT_COUNT; i++) {
253 129 0 if (!sv || SvTYPE(sv) != SVt_PVHV)
0 129 if (!sv || SvTYPE(sv) != SVt_PVHV)
282 1 7293 if (p_state->parsing)
285 47 7246 if (SvROK(chunk) && SvTYPE(SvRV(chunk)) == SVt_PVCV) {
47 0 if (SvROK(chunk) && SvTYPE(SvRV(chunk)) == SVt_PVCV) {
290 0 275 PUSHMARK(SP);
293 275 0 chunk = count ? POPs : 0;
296 275 0 if (SvTRUE(ERRSV)) {
1 274 if (SvTRUE(ERRSV)) {
302 274 0 if (chunk && SvOK(chunk)) {
274 0 if (chunk && SvOK(chunk)) {
308 228 46 parse(aTHX_ p_state, len ? chunk : 0, self);
311 228 46 } while (len && !p_state->eof);
228 0 } while (len && !p_state->eof);
318 9 7282 if (p_state->eof) {
332 11 151 if (p_state->parsing)
384 17 89 RETVAL = boolSV(*attr);
385 87 19 if (items > 1)
395 3 2 : &PL_sv_undef;
396 3 2 if (items > 1) {
421 0 37 if (GIMME_V != G_VOID)
425 34 3 if (items) {
426 3 31 if (*attr)
431 41 34 for (i = 0; i < items; i++) {
433 14 27 if (SvROK(sv)) {
435 14 0 if (SvTYPE(sv) == SVt_PVAV) {
438 0 14 STRLEN top = av_top_index(av);
439 107 14 for (j = 0; j <= top; j++) {
441 107 0 if (svp) {
454 3 0 else if (*attr) {
471 2270 1 for (i = 0; i < EVENT_COUNT; i++) {
472 525 1745 if (strEQ(name, event_id_str[i])) {
477 1 525 if (event < 0)
483 64 461 if (h->cb) {
484 50 14 PUSHs((SvTYPE(h->cb) == SVt_PVAV)
493 463 62 if (items > 3) {
498 514 5 if (items > 2) {
513 36 29 if (GIMME_V == G_SCALAR && items > 1)
0 36 if (GIMME_V == G_SCALAR && items > 1)
515 65 65 for (i = 0; i < items; i++) {
516 36 29 if (GIMME_V != G_VOID)
520 8 21 SV_CHECK_THINKFIRST(ST(i));
522 0 29 if (SvREADONLY(ST(i)))
535 1 13 bool expand_prefix = (items > 2) ? SvTRUE(ST(2)) : 0;
1 0 bool expand_prefix = (items > 2) ? SvTRUE(ST(2)) : 0;
537 12 2 if (SvOK(entities)) {
538 11 1 if (SvROK(entities) && SvTYPE(SvRV(entities)) == SVt_PVHV) {
10 1 if (SvROK(entities) && SvTYPE(SvRV(entities)) == SVt_PVHV) {
549 5 7 SV_CHECK_THINKFIRST(string);
551 0 11 if (SvREADONLY(string))
572 0 3 RETVAL = 1;