At 06:30 PM 1/6/2002 -0800, Hong Zhang wrote: > > That's what I thought I remembered; in that case, here's a patch: > > > > Index: core.ops > > =================================================================== > > RCS file: /home/perlcvs/parrot/core.ops,v > > retrieving revision 1.68 > > diff -u -r1.68 core.ops > > --- core.ops 4 Jan 2002 02:36:25 -0000 1.68 > > +++ core.ops 5 Jan 2002 03:58:14 -0000 > > @@ -463,8 +463,8 @@ > > =cut > > > > op write(i|ic, i|ic) { > > - INTVAL * i = &($2); > > - write($1, i, sizeof(INTVAL)); > > + INTVAL i = (INTVAL)$2; > > + write($1, &i, sizeof(INTVAL)); > > goto NEXT(); > > } > >I think the above code is wrong. It should be > >I32 i = (I32) $2; >write($1, &i, 4); > >I am not sure why you want to write all INTVAL bytes when only >the lower 32-bit are valid.
What if sizeof(INTVAL) != 4 ? Are you saying we have different ops for i32 and i64 values? In any case the read/write etc. stuff is just temporary, they aren't the permanent IO routines we will end up with, just something until we have a real IO system. -Melvin