On Wed, Mar 18, 2015 at 9:57 AM, Guillermo Polito <guillermopolito@gmail.com
wrote:
In Pharo it is similar. However, we would like to have an image where BitBlt and Form are not there.
Here's one that works on both Spur and V3. It only works on a Cog or Stack VM (and hence is OK for Pharo) since it depends on Floats being stored in the platform order internally.
| f | f := Float new. f at: 2 put: 1. "store the least significant word of the float with 1; on big endian machines this is the second word" Bitmap adoptInstance: f. f first = 1 ifTrue: [#little] ifFalse: [#big]
El mié., 18 de mar. de 2015 a la(s) 5:52 p. m., David T. Lewis < lewis@mail.msen.com> escribió:
It is easy to add a primitive for this, but it should not be necessary. See SmalltalkImage>>calcEndianness in Squeak.
Dave
Hello,
Is there a primitive or a parameter that I can call from the image to
know
the endianness of the processor / VM ?
Thanks,
Clement