Re: [fpc-pascal] Floating-point number representation on various platforms

2006-02-18 Thread Tom Verhoeff
On Sat, Feb 18, 2006 at 09:43:31AM +0100, Tom Verhoeff wrote: > > So, here are some pieces of the code, it uses a variant array to > access the bits of the IEEE floating-point numbers in Single and Double: That should be 'record' insteady of 'array', of course. Tom -- E-MAIL: T.Verhoeff

Re: [fpc-pascal] Floating-point number representation on various platforms

2006-02-18 Thread Tom Verhoeff
On Sun, Feb 05, 2006 at 01:39:25PM +0100, Jonas Maebe wrote: > > On 05 Feb 2006, at 13:32, Tom Verhoeff wrote: > > >Question 2: Any suggestions as to how to make it more platform > >independent, > >or how to support multiple platforms in an easy way? > > The only differences are little/big end

Re: [fpc-pascal] Floating-point number representation on various platforms

2006-02-05 Thread Jonas Maebe
On 05 Feb 2006, at 13:32, Tom Verhoeff wrote: Question 2: Any suggestions as to how to make it more platform independent, or how to support multiple platforms in an easy way? The only differences are little/big endian. So if it works on PPC and I386, you have support for all platforms. Ju

[fpc-pascal] Floating-point number representation on various platforms

2006-02-05 Thread Tom Verhoeff
While writing a paper (several years ago) about the traps of using floating-point numbers, I prepared a unit FloatView to "play" with the internal representation according to the IEEE Std, including to print it in various formats. Initially, I made this work for the Linux/i386 platform only. Late