Floats in squeak...

Joshua 'Schwa' Gargus schwa at cc.gatech.edu
Sat Sep 6 05:29:45 UTC 2003


On Fri, Sep 05, 2003 at 09:28:51PM -0700, Ned Konz wrote:
> On Friday 05 September 2003 07:27 pm, Joshua 'Schwa' Gargus wrote:
> 
> > Well, that and because I'm now having the same problem.  Here is a
> > snippet that is pretty close to the root of the problem:
> >
> > #(1 3 5) asFloatArray += 2.5
> > ==> a FloatArray(1.0 3.0 5.0)
> >
> 
> On my Linux VM (compiled with GCC v3.3):
> 
> #(1 3 5) asFloatArray += 2.5
> -->  a FloatArray(3.5 5.5 7.5)

(pulls out calculator)  Yes, that looks right :-)

> 
> Have you tried making the FloatArrayPlugin internal?

No, I'll try that next.

Other things I've tried: I verified that the 'fetchFloatAtinto' macro
being used is the first one (the one that does swapping for
little-endian architectures).  However, the value being fetched is 0.0
for some reason that I haven't yet figured out.

Internal FloatArrayPlugin, then bed!

Thanks for the help,
Joshua



> 
> Smalltalk listLoadedModules
> ->  #('LargeIntegers v1.2 3 September 2003 (i)' 'B2DPlugin 3 September 
> 2003 (i)' 'Matrix2x3Plugin 3 September 2003 (i)' 'FloatArrayPlugin 3 
> September 2003 (i)' 'BitBltPlugin 3 September 2003 (i)' 
> 'SecurityPlugin 3 September 2003 (i)' 'FilePlugin 3 September 2003 
> (i)' 'MiscPrimitivePlugin 3 September 2003 (i)')
> 
> -- 
> Ned Konz
> http://bike-nomad.com
> GPG key ID: BEEA7EFE
> 



More information about the Squeak-dev mailing list