Skip to content

Commit

Permalink
Fixed unused variable / self-assignment compiler warnings
Browse files Browse the repository at this point in the history
git-svn-id: https://svn.perl.org/modules/dbi/trunk@15353 50811bd7-b8ce-0310-adc1-d9db26280581
  • Loading branch information
timbunce committed Jul 13, 2012
1 parent 1e5cb22 commit f1e5d53
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
10 changes: 5 additions & 5 deletions Driver.xst
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ REQUIRE: 1.929
PROTOTYPES: DISABLE

BOOT:
items = 0; /* avoid 'unused variable' warning */
PERL_UNUSED_VAR(items);
DBISTATE_INIT;
/* XXX this interface will change: */
DBI_IMP_SIZE("DBD::~DRIVER~::dr::imp_data_size", sizeof(imp_drh_t));
Expand Down Expand Up @@ -46,7 +46,7 @@ discon_all_(drh)
disconnect_all = 1
CODE:
D_imp_drh(drh);
if (0) ix = ix; /* avoid unused variable warning */
PERL_UNUSED_VAR(ix);
ST(0) = dbd_discon_all(drh, imp_drh) ? &PL_sv_yes : &PL_sv_no;

#endif /* dbd_discon_all */
Expand Down Expand Up @@ -623,7 +623,7 @@ fetchrow_arrayref(sth)
CODE:
D_imp_sth(sth);
AV *av;
if (0) ix = ix; /* avoid unused variable warning */
PERL_UNUSED_VAR(ix);
av = dbd_st_fetch(sth, imp_sth);
ST(0) = (av) ? sv_2mortal(newRV((SV *)av)) : &PL_sv_undef;

Expand All @@ -644,7 +644,7 @@ fetchrow_array(sth)
for(i=0; i < num_fields; ++i) {
PUSHs(AvARRAY(av)[i]);
}
if (0) ix = ix; /* avoid unused variable warning */
PERL_UNUSED_VAR(ix);
}


Expand Down Expand Up @@ -731,7 +731,7 @@ FETCH_attrib(sth, keysv)
CODE:
D_imp_sth(sth);
SV *valuesv;
if (0) ix = ix; /* avoid unused variable warning */
PERL_UNUSED_VAR(ix);
valuesv = dbd_st_FETCH_attrib(sth, imp_sth, keysv);
if (!valuesv)
valuesv = DBIc_DBISTATE(imp_sth)->get_attr(sth, keysv);
Expand Down
2 changes: 1 addition & 1 deletion Driver_xst.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ dbixst_bounce_method(char *methname, int params)
if (debug >= 3) {
PerlIO_printf(DBIc_LOGPIO(imp_xxh),
" -> %s (trampoline call with %d (%ld) params)\n", methname, params, (long)items);
xxx = xxx; /* avoid unused var warning */
PERL_UNUSED_VAR(xxx);
}
EXTEND(SP, params);
PUSHMARK(SP);
Expand Down
6 changes: 3 additions & 3 deletions dbixs_rev.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* Wed Apr 18 12:37:44 2012 */
/* Mixed revision working copy (15267M:15268) */
/* Fri Jul 13 13:29:50 2012 */
/* Mixed revision working copy (15349M:15352) */
/* Code modified since last checkin */
#define DBIXS_REVISION 15267
#define DBIXS_REVISION 15349

0 comments on commit f1e5d53

Please sign in to comment.