Craig A. Berry <[EMAIL PROTECTED]> writes:
>With recent versions of Compaq C under OpenVMS, the latest Storable 
>version fails to compile like so:
>
>CC/DECC 
>/Include=[]/Standard=Relaxed_ANSI/Prefix=All/Obj=.obj/NoList/NOANSI_ALIAS/Define=("VERSION=""2.06""","XS_VERSION=""2.06""")/
>Include=(perl_root:[lib.VMS_AXP.5_6_1.CORE])/Optimize  STORABLE.c
>
>     WRITE(header, length);
>....^
>%CC-W-NOTCONSTQUAL, In this statement, the referenced type of the 
>pointer value "header" is const, but the referenced type of the target 
>of this assignment is not.
>at line number 3369 in file D0:[CRAIG.STORABLE-2_06]STORABLE.XS;1

What would it take to make WRITE(const char *,...) ?


>
>The patch below takes care of this, after which the extension builds ok 
>  and all tests pass under Perl 5.6.1, OpenVMS Alpha 7.3-1, Compaq C 6.5.
>--- Storable.XS;-0     Mon Nov 25 05:57:21 2002
>+++ Storable.XS        Thu Jan 23 15:39:24 2003
>@@ -3366,7 +3366,7 @@
>         length -= sizeof (magicstr) - 1;
>     }        
> 
>-    WRITE(header, length);
>+    WRITE( (unsigned char*) header, length);
> 
>     if (!cxt->netorder) {
>       TRACEME(("ok (magic_write byteorder = 0x%lx [%d], I%d L%d P%d D%d)",
-- 
Nick Ing-Simmons
http://www.ni-s.u-net.com/

Reply via email to