Hi Bram,

The attached patch updates the if_perl code to use the usual XS macros
for casting between external pointers and their "scalar value"s.  This
fixes the warnings mentioned in the subject.

Cheers,
-- 
James
GPG Key: 4096R/331BA3DB 2011-12-05 James McCoy <[email protected]>
diff --git a/src/if_perl.xs b/src/if_perl.xs
--- a/src/if_perl.xs
+++ b/src/if_perl.xs
@@ -611,7 +611,7 @@
     if (ptr->w_perl_private == NULL)
     {
 	ptr->w_perl_private = newSV(0);
-	sv_setiv(ptr->w_perl_private, (IV)ptr);
+	sv_setiv(ptr->w_perl_private, PTR2IV(ptr));
     }
     else
 	SvREFCNT_inc(ptr->w_perl_private);
@@ -629,7 +629,7 @@
     if (ptr->b_perl_private == NULL)
     {
 	ptr->b_perl_private = newSV(0);
-	sv_setiv(ptr->b_perl_private, (IV)ptr);
+	sv_setiv(ptr->b_perl_private, PTR2IV(ptr));
     }
     else
 	SvREFCNT_inc(ptr->b_perl_private);
diff --git a/src/typemap b/src/typemap
--- a/src/typemap
+++ b/src/typemap
@@ -6,7 +6,7 @@
 T_VIOBJNOMUNGE
 	if (sv_isa($arg, \"${ntype}\")) {
 	    IV tmp = SvIV((SV*)SvRV($arg));
-	    $var = ($type) tmp;
+	    $var = INT2PTR($type, tmp);
 	    if (!tmp)
 		croak(\"$ntype no longer exists\");
 	}

Attachment: signature.asc
Description: Digital signature

Raspunde prin e-mail lui