This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
ext/ + -Wall
[perl5.git] / ext / DB_File / DB_File.xs
index 8a9ce8a..4942e25 100644 (file)
@@ -95,6 +95,7 @@
 
 */
 
+#define PERL_NO_GET_CONTEXT
 #include "EXTERN.h"  
 #include "perl.h"
 #include "XSUB.h"
 
 #endif
 
+/* avoid -Wall; DB_File xsubs never make use of `ix' setup for ALIASes */
+#undef dXSI32
+#define dXSI32 dNOOP
+
 /* If Perl has been compiled with Threads support,the symbol op will
    be defined here. This clashes with a field name in db.h, so get rid of it.
  */
@@ -1703,11 +1708,13 @@ db_EXISTS(db, key)
        OUTPUT:
          RETVAL
 
-int
+void
 db_FETCH(db, key, flags=0)
        DB_File         db
        DBTKEY          key
        u_int           flags
+       PREINIT:
+       int RETVAL;
        CODE:
        {
             DBT                value ;
@@ -1730,9 +1737,11 @@ db_STORE(db, key, value, flags=0)
          CurrentDB = db ;
 
 
-int
+void
 db_FIRSTKEY(db)
        DB_File         db
+       PREINIT:
+       int RETVAL;
        CODE:
        {
            DBTKEY      key ;
@@ -1746,10 +1755,12 @@ db_FIRSTKEY(db)
            OutputKey(ST(0), key) ;
        }
 
-int
+void
 db_NEXTKEY(db, key)
        DB_File         db
        DBTKEY          key
+       PREINIT:
+       int RETVAL;
        CODE:
        {
            DBT         value ;
@@ -1806,10 +1817,12 @@ unshift(db, ...)
        OUTPUT:
            RETVAL
 
-I32
+void
 pop(db)
        DB_File         db
        ALIAS:          POP = 1
+       PREINIT:
+       I32 RETVAL;
        CODE:
        {
            DBTKEY      key ;
@@ -1833,10 +1846,12 @@ pop(db)
            }
        }
 
-I32
+void
 shift(db)
        DB_File         db
        ALIAS:          SHIFT = 1
+       PREINIT:
+       I32 RETVAL;
        CODE:
        {
            DBT         value ;