Re: NV Constants

2001-09-30 Thread Bryan C . Warnock
On Sunday 30 September 2001 08:46 pm, Simon Cozens wrote: > It's to do with me being confused between the size of the NV pointer > (which is an IV) Not necessarily. -- Bryan C. Warnock [EMAIL PROTECTED]

Re: NV Constants

2001-09-30 Thread Simon Cozens
On Sun, Sep 30, 2001 at 07:07:34PM -0500, Gibbs Tanton - tgibbs wrote: > mem_sys_memcopy( &value, cursor, sizeof(NV) ) I'm being stupid. Of course that ought to work. (And it does, everywhere it matters.) > does the sizeof(IV) have something to do with it? It's to do with me being confused

RE: NV Constants

2001-09-30 Thread Gibbs Tanton - tgibbs
BTW, Cygwin works fine (although -Wall issues a number of warnings related to the printf flags). -Original Message- From: Simon Cozens To: Gregor N. Purdy Cc: '[EMAIL PROTECTED]'; [EMAIL PROTECTED] Sent: 9/30/2001 3:21 PM Subject: Re: NV Constants On Sun, Sep 30, 2001 at

RE: NV Constants

2001-09-30 Thread Gibbs Tanton - tgibbs
er...does the sizeof(IV) have something to do with it? This code does not look right at all...can you help me understand? -Original Message- From: Simon Cozens To: Gregor N. Purdy Cc: '[EMAIL PROTECTED]'; [EMAIL PROTECTED] Sent: 9/30/2001 3:21 PM Subject: Re: NV Constants On Sun,

RE: NV Constants

2001-09-30 Thread Hong Zhang
> > The memcpy() can handle alignment nicely. > > Not always. I tried. :( How that could be possible? The memcpy() just does byte-by-byte copy. It does not care anything about the alignment of source or dest. How can it fail? Hong

Re: NV Constants

2001-09-30 Thread Simon Cozens
On Sun, Sep 30, 2001 at 01:37:44PM -0700, Hong Zhang wrote: > The memcpy() can handle alignment nicely. Not always. I tried. :( -- "How should I know if it works? That's what beta testers are for. I only coded it." (Attributed to Linus Torvalds, somewhere in a posting)

RE: NV Constants

2001-09-30 Thread Hong Zhang
> This was failing here until I made the following change: > > PackFile_Constant_unpack_number(struct PackFile_Constant * > self, char * packed, IV packed_size) { > char * cursor; > NV value; > NV * aligned = mem_sys_allocate(sizeof(IV)); Are you sure this is correct? Or this

Re: NV Constants

2001-09-30 Thread Simon Cozens
On Sun, Sep 30, 2001 at 11:25:04AM -0400, Gregor N. Purdy wrote: > * Solaris (Sparc) This was failing here until I made the following change: PackFile_Constant_unpack_number(struct PackFile_Constant * self, char * packed, IV packed_size) { char * cursor; NV value; NV * align

Re: NV Constants

2001-09-30 Thread Gregor N. Purdy
Gibbs -- > I tested the patch on CygWin, Solaris SunOS 5.8, and Tru64. It passed on > all three systems. Thanks! Here's the platform status of this work: CORE PASSED: * Linux (x86) * CygWin * True64 * Solaris (Sparc) CORE NOT TESTED: * Win32 * OpenVMS (Alpha) * FreeBSD (x86)