line |
true |
false |
branch |
34
|
0 |
50 |
PUSHMARK(SP); |
35
|
0 |
50 |
XPUSHs(((perl_vtab *) pVTab)->perl_vtab_obj); |
36
|
0 |
50 |
XPUSHs(sv_2mortal(newSViv(i))); |
43
|
50 |
0 |
FREETMPS; |
66
|
0 |
15 |
if( vt==NULL ) return SQLITE_NOMEM; |
74
|
0 |
15 |
PUSHMARK(SP); |
75
|
0 |
15 |
XPUSHs(sv_2mortal(newSVpv(init_data->perl_class, 0))); |
76
|
0 |
15 |
XPUSHs(init_data->dbh); |
77
|
88 |
15 |
for(i = 0; i < argc; i++) { |
78
|
0 |
88 |
XPUSHs(newSVpvn_flags(argv[i], strlen(argv[i]), SVs_TEMP|SVf_UTF8)); |
85
|
0 |
15 |
if ( count != 1 ) { |
94
|
0 |
15 |
if ( !sv_isobject(perl_vtab_obj) ) { |
101
|
0 |
15 |
PUSHMARK(SP); |
102
|
0 |
15 |
XPUSHs(perl_vtab_obj); |
108
|
0 |
15 |
if (count != 1 ) { |
118
|
15 |
0 |
rc = sqlite3_declare_vtab(db, SvPVutf8_nolen(sql)); |
121
|
15 |
0 |
if (rc == SQLITE_OK) { |
131
|
15 |
0 |
FREETMPS; |
233
|
54 |
64 |
for (i=0; inConstraint; i++){ |
239
|
54 |
0 |
hv_stores(constraint, "usable", pCons->usable ? &PL_sv_yes : &PL_sv_no); |
245
|
21 |
64 |
for (i=0; inOrderBy; i++){ |
249
|
2 |
19 |
hv_stores(order, "desc", pOrder->desc ? &PL_sv_yes : &PL_sv_no); |
254
|
0 |
64 |
PUSHMARK(SP); |
255
|
0 |
64 |
XPUSHs( ((perl_vtab *) pVTab)->perl_vtab_obj); |
256
|
0 |
64 |
XPUSHs( sv_2mortal( newRV_noinc((SV*) constraints))); |
257
|
0 |
64 |
XPUSHs( sv_2mortal( newRV_noinc((SV*) order_by))); |
263
|
0 |
64 |
if (count != 1) |
266
|
64 |
0 |
if (!(hashref && SvROK(hashref) && SvTYPE(SvRV(hashref)) == SVt_PVHV)) |
|
64 |
0 |
if (!(hashref && SvROK(hashref) && SvTYPE(SvRV(hashref)) == SVt_PVHV)) |
|
0 |
64 |
if (!(hashref && SvROK(hashref) && SvTYPE(SvRV(hashref)) == SVt_PVHV)) |
270
|
64 |
0 |
pIdxInfo->idxNum = (val && SvOK(*val)) ? SvIV(*val) : 0; |
|
0 |
64 |
pIdxInfo->idxNum = (val && SvOK(*val)) ? SvIV(*val) : 0; |
|
0 |
0 |
pIdxInfo->idxNum = (val && SvOK(*val)) ? SvIV(*val) : 0; |
|
0 |
0 |
pIdxInfo->idxNum = (val && SvOK(*val)) ? SvIV(*val) : 0; |
|
64 |
0 |
pIdxInfo->idxNum = (val && SvOK(*val)) ? SvIV(*val) : 0; |
272
|
64 |
0 |
if (val && SvOK(*val)) { |
|
0 |
64 |
if (val && SvOK(*val)) { |
|
0 |
0 |
if (val && SvOK(*val)) { |
|
0 |
0 |
if (val && SvOK(*val)) { |
274
|
0 |
64 |
char *str = SvPVutf8(*val, len); |
281
|
64 |
0 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
64 |
0 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
64 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
64 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
64 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
64 |
0 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
64 |
0 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
64 |
0 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
64 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
64 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pIdxInfo->orderByConsumed = (val && SvTRUE(*val)) ? 1 : 0; |
283
|
64 |
0 |
pIdxInfo->estimatedCost = (val && SvOK(*val)) ? SvNV(*val) : 0; |
|
0 |
64 |
pIdxInfo->estimatedCost = (val && SvOK(*val)) ? SvNV(*val) : 0; |
|
0 |
0 |
pIdxInfo->estimatedCost = (val && SvOK(*val)) ? SvNV(*val) : 0; |
|
0 |
0 |
pIdxInfo->estimatedCost = (val && SvOK(*val)) ? SvNV(*val) : 0; |
|
64 |
0 |
pIdxInfo->estimatedCost = (val && SvOK(*val)) ? SvNV(*val) : 0; |
286
|
64 |
0 |
pIdxInfo->estimatedRows = (val && SvOK(*val)) ? SvIV(*val) : 0; |
|
64 |
0 |
pIdxInfo->estimatedRows = (val && SvOK(*val)) ? SvIV(*val) : 0; |
|
64 |
0 |
pIdxInfo->estimatedRows = (val && SvOK(*val)) ? SvIV(*val) : 0; |
|
0 |
64 |
pIdxInfo->estimatedRows = (val && SvOK(*val)) ? SvIV(*val) : 0; |
|
0 |
0 |
pIdxInfo->estimatedRows = (val && SvOK(*val)) ? SvIV(*val) : 0; |
291
|
54 |
64 |
for (i=0; inConstraint; i++){ |
293
|
54 |
0 |
if (!(rv && SvROK(*rv) && SvTYPE(SvRV(*rv)) == SVt_PVHV)) |
|
54 |
0 |
if (!(rv && SvROK(*rv) && SvTYPE(SvRV(*rv)) == SVt_PVHV)) |
|
0 |
54 |
if (!(rv && SvROK(*rv) && SvTYPE(SvRV(*rv)) == SVt_PVHV)) |
297
|
53 |
1 |
argvIndex = (val && SvOK(*val)) ? SvIV(*val) + 1: 0; |
|
0 |
53 |
argvIndex = (val && SvOK(*val)) ? SvIV(*val) + 1: 0; |
|
0 |
0 |
argvIndex = (val && SvOK(*val)) ? SvIV(*val) + 1: 0; |
|
0 |
0 |
argvIndex = (val && SvOK(*val)) ? SvIV(*val) + 1: 0; |
|
53 |
0 |
argvIndex = (val && SvOK(*val)) ? SvIV(*val) + 1: 0; |
302
|
53 |
1 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
53 |
0 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
53 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
53 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
53 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
53 |
0 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
53 |
0 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
53 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
53 |
0 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
|
0 |
0 |
pConsUsage->omit = (val && SvTRUE(*val)) ? 1 : 0; |
306
|
64 |
0 |
FREETMPS; |
327
|
0 |
107 |
if( cursor==NULL ) return SQLITE_NOMEM; |
331
|
0 |
107 |
PUSHMARK(SP); |
332
|
0 |
107 |
XPUSHs( ((perl_vtab *) pVTab)->perl_vtab_obj); |
336
|
0 |
107 |
if (count != 1) { |
343
|
0 |
107 |
if ( !sv_isobject(perl_cursor) ) { |
353
|
107 |
0 |
if (rc == SQLITE_OK) { |
362
|
107 |
0 |
FREETMPS; |
384
|
7 |
100 |
FREETMPS; |
403
|
0 |
116 |
PUSHMARK(SP); |
404
|
0 |
116 |
XPUSHs(((perl_vtab_cursor *) pVtabCursor)->perl_cursor_obj); |
405
|
0 |
116 |
XPUSHs(sv_2mortal(newSViv(idxNum))); |
406
|
0 |
116 |
XPUSHs(sv_2mortal(newSVpv(idxStr, 0))); |
407
|
108 |
116 |
for(i = 0; i < argc; i++) { |
408
|
0 |
108 |
XPUSHs(stacked_sv_from_sqlite3_value(aTHX_ argv[i], is_unicode)); |
416
|
116 |
0 |
FREETMPS; |
432
|
0 |
142 |
PUSHMARK(SP); |
433
|
0 |
142 |
XPUSHs(((perl_vtab_cursor *) pVtabCursor)->perl_cursor_obj); |
440
|
142 |
0 |
FREETMPS; |
455
|
0 |
258 |
PUSHMARK(SP); |
456
|
0 |
258 |
XPUSHs(((perl_vtab_cursor *) pVtabCursor)->perl_cursor_obj); |
460
|
0 |
258 |
if (count != 1) { |
466
|
258 |
0 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
|
0 |
258 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
|
0 |
0 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
|
0 |
258 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
|
0 |
0 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
|
0 |
0 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
|
258 |
0 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
|
258 |
0 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
|
258 |
0 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
|
64 |
194 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
|
64 |
0 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
|
64 |
194 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
|
0 |
0 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
|
0 |
0 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
|
0 |
0 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
|
0 |
0 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
|
0 |
0 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
|
0 |
0 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
|
0 |
0 |
eof = SvTRUE(sv); /* eof = SvTRUE(POPs); # I don't understand why :-( */ |
470
|
258 |
0 |
FREETMPS; |
489
|
0 |
461 |
PUSHMARK(SP); |
490
|
0 |
461 |
XPUSHs(((perl_vtab_cursor *) pVtabCursor)->perl_cursor_obj); |
491
|
0 |
461 |
XPUSHs(sv_2mortal(newSViv(col))); |
495
|
0 |
461 |
if (count != 1) { |
507
|
461 |
0 |
FREETMPS; |
524
|
0 |
83 |
PUSHMARK(SP); |
525
|
0 |
83 |
XPUSHs(((perl_vtab_cursor *) pVtabCursor)->perl_cursor_obj); |
529
|
0 |
83 |
if (count != 1) { |
534
|
83 |
0 |
*pRowid =POPi; |
539
|
83 |
0 |
FREETMPS; |
560
|
0 |
5 |
PUSHMARK(SP); |
561
|
0 |
5 |
XPUSHs(((perl_vtab *) pVTab)->perl_vtab_obj); |
562
|
17 |
5 |
for(i = 0; i < argc; i++) { |
563
|
0 |
17 |
XPUSHs(stacked_sv_from_sqlite3_value(aTHX_ argv[i], is_unicode)); |
568
|
0 |
5 |
if (count != 1) { |
573
|
5 |
0 |
if (argc > 1 && sqlite3_value_type(argv[0]) == SQLITE_NULL |
|
5 |
0 |
if (argc > 1 && sqlite3_value_type(argv[0]) == SQLITE_NULL |
574
|
5 |
0 |
&& sqlite3_value_type(argv[1]) == SQLITE_NULL) { |
578
|
0 |
5 |
if (!SvOK(rowidsv)) |
|
0 |
0 |
if (!SvOK(rowidsv)) |
|
0 |
0 |
if (!SvOK(rowidsv)) |
580
|
0 |
5 |
else if (SvUOK(rowidsv)) |
581
|
0 |
0 |
*pRowid = SvUV(rowidsv); |
582
|
5 |
0 |
else if (SvIOK(rowidsv)) |
583
|
5 |
0 |
*pRowid = SvIV(rowidsv); |
585
|
0 |
0 |
*pRowid = (sqlite3_int64)SvNV(rowidsv); |
592
|
5 |
0 |
FREETMPS; |
634
|
6 |
7 |
if (hv_exists(functions, func_name, len)) { |
636
|
6 |
0 |
if (val && SvOK(*val)) { |
|
1 |
5 |
if (val && SvOK(*val)) { |
|
1 |
0 |
if (val && SvOK(*val)) { |
|
0 |
1 |
if (val && SvOK(*val)) { |
642
|
0 |
7 |
PUSHMARK(SP); |
643
|
0 |
7 |
XPUSHs(((perl_vtab *) pVTab)->perl_vtab_obj); |
644
|
0 |
7 |
XPUSHs(sv_2mortal(newSViv(nArg))); |
645
|
0 |
7 |
XPUSHs(sv_2mortal(newSVpv(zName, 0))); |
649
|
0 |
7 |
if (count != 1) { |
655
|
7 |
0 |
if (SvTRUE(result)) { |
|
0 |
7 |
if (SvTRUE(result)) { |
|
2 |
5 |
if (SvTRUE(result)) { |
|
2 |
0 |
if (SvTRUE(result)) { |
|
0 |
2 |
if (SvTRUE(result)) { |
|
0 |
5 |
if (SvTRUE(result)) { |
|
0 |
0 |
if (SvTRUE(result)) { |
|
0 |
0 |
if (SvTRUE(result)) { |
|
0 |
0 |
if (SvTRUE(result)) { |
|
0 |
0 |
if (SvTRUE(result)) { |
|
1 |
4 |
if (SvTRUE(result)) { |
|
1 |
0 |
if (SvTRUE(result)) { |
|
1 |
0 |
if (SvTRUE(result)) { |
|
0 |
1 |
if (SvTRUE(result)) { |
|
0 |
0 |
if (SvTRUE(result)) { |
|
4 |
3 |
if (SvTRUE(result)) { |
662
|
4 |
3 |
hv_store(functions, func_name, len, coderef ? coderef : &PL_sv_undef, 0); |
666
|
9 |
4 |
is_overloaded = coderef && SvTRUE(coderef); |
|
9 |
0 |
is_overloaded = coderef && SvTRUE(coderef); |
|
0 |
9 |
is_overloaded = coderef && SvTRUE(coderef); |
|
0 |
0 |
is_overloaded = coderef && SvTRUE(coderef); |
|
0 |
9 |
is_overloaded = coderef && SvTRUE(coderef); |
|
0 |
0 |
is_overloaded = coderef && SvTRUE(coderef); |
|
0 |
0 |
is_overloaded = coderef && SvTRUE(coderef); |
|
0 |
9 |
is_overloaded = coderef && SvTRUE(coderef); |
|
0 |
0 |
is_overloaded = coderef && SvTRUE(coderef); |
|
0 |
0 |
is_overloaded = coderef && SvTRUE(coderef); |
|
0 |
0 |
is_overloaded = coderef && SvTRUE(coderef); |
|
0 |
0 |
is_overloaded = coderef && SvTRUE(coderef); |
|
0 |
0 |
is_overloaded = coderef && SvTRUE(coderef); |
|
0 |
9 |
is_overloaded = coderef && SvTRUE(coderef); |
|
0 |
0 |
is_overloaded = coderef && SvTRUE(coderef); |
|
0 |
0 |
is_overloaded = coderef && SvTRUE(coderef); |
|
0 |
0 |
is_overloaded = coderef && SvTRUE(coderef); |
|
0 |
0 |
is_overloaded = coderef && SvTRUE(coderef); |
|
0 |
0 |
is_overloaded = coderef && SvTRUE(coderef); |
|
9 |
0 |
is_overloaded = coderef && SvTRUE(coderef); |
667
|
9 |
4 |
if (is_overloaded) { |
669
|
0 |
9 |
: sqlite_db_func_dispatcher_no_unicode; |
675
|
7 |
6 |
FREETMPS; |
691
|
0 |
0 |
PUSHMARK(SP); |
692
|
0 |
0 |
XPUSHs(((perl_vtab *) pVTab)->perl_vtab_obj); |
693
|
0 |
0 |
XPUSHs(sv_2mortal(newSVpv(zNew, 0))); |
697
|
0 |
0 |
if (count != 1) { |
702
|
0 |
0 |
rc = POPi; |
706
|
0 |
0 |
FREETMPS; |
768
|
0 |
11 |
PUSHMARK(SP); |
769
|
0 |
11 |
XPUSHs(sv_2mortal(newSVpv(init_data->perl_class, 0))); |
780
|
11 |
0 |
FREETMPS; |
799
|
0 |
11 |
if (!DBIc_ACTIVE(imp_dbh)) { |
806
|
5 |
6 |
if (!get_av(module_ISA, 0)) { |
826
|
0 |
11 |
if ( rc != SQLITE_OK ) { |
834
|
0 |
11 |
PUSHMARK(SP); |
835
|
0 |
11 |
XPUSHs(sv_2mortal(newSVpv(perl_class, 0))); |
836
|
0 |
11 |
XPUSHs(sv_2mortal(newSVpv(name, 0))); |
843
|
11 |
0 |
FREETMPS; |