This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Few more casts, need reported in
authorJarkko Hietaniemi <jhi@iki.fi>
Mon, 21 Aug 2000 22:22:32 +0000 (22:22 +0000)
committerJarkko Hietaniemi <jhi@iki.fi>
Mon, 21 Aug 2000 22:22:32 +0000 (22:22 +0000)
Subject: Re: [ID 20000821.010] OK: perl v5.7.0 +SUIDMAIL +DEVEL6756 on i586-linux-64all 2.2.16-9mdk (UNINSTALLED)
From: Mike Stok <mike@stok.co.uk>
Date: Mon, 21 Aug 2000 15:59:29 -0500 (CDT)
Message-ID: <Pine.LNX.4.21.0008211558480.19081-100000@ratdog.stok.co.uk>

and

Subject: [ID 20000821.013] Not OK: perl v5.7.0 +SUIDMAIL +DEVEL6756 on i686-linux-64int 2.2.13
From: abigail@foad.org
Date: 21 Aug 2000 21:31:34 -0000
Message-Id: <20000821213134.30170.qmail@foad.org>

p4raw-id: //depot/perl@6758

ext/Storable/Storable.xs

index 0cdad85..997d23b 100644 (file)
@@ -1298,11 +1298,10 @@ I32 *classnum;
 
        /*
         * Unknown classname, we need to record it.
-        * The (IV) cast below is for 64-bit machines, to avoid compiler warnings.
         */
 
        cxt->classnum++;
-       if (!hv_store(hclass, name, len, (SV*)(IV) cxt->classnum, 0))
+       if (!hv_store(hclass, name, len, INT2PTR(SV*, cxt->classnum), 0))
                CROAK(("Unable to record new classname"));
 
        *classnum = cxt->classnum;
@@ -2425,14 +2424,11 @@ SV *sv;
         * means that we must clean up the hash manually afterwards, but gives
         * us a 15% throughput increase.
         *
-        * The (IV) cast below is for 64-bit machines, to avoid warnings from
-        * the compiler. Please, let me know if it does not work.
-        *              -- RAM, 14/09/1999
         */
 
        cxt->tagnum++;
        if (!hv_store(hseen,
-                       (char *) &sv, sizeof(sv), (SV*)(IV) cxt->tagnum, 0))
+                       (char *) &sv, sizeof(sv), INT2PTR(SV*, cxt->tagnum), 0))
                return -1;
 
        /*