BitArray and BooleanArray ?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

BitArray and BooleanArray ?

vonbecmann
Hi,
  why there isn't a BitArray or BooleanArray in the collection library?
  is there a sustitute for that?

thanks

--
Bernardo E.C.

Sent from a cheap desktop computer in South America.
Reply | Threaded
Open this post in threaded view
|

Re: BitArray and BooleanArray ?

Ben Coman
I don't know the answer but I assume you a looking for a memory
efficient way of storing booleans.  So perhaps the Bit Field layouts
discussed here [1] may be of interest considering the recent
introduction of Slots to Pharo.  Otherwise I verry vaguely remember
Bitmap used for this somewhere. Sorry I can't be more precise.

[1] http://rmod.inria.fr/archives/papers/Verw11a-OOSPLA11-FlexibleObjectLayouts.pdf

cheers -ben

On Thu, Sep 1, 2016 at 1:32 AM, Bernardo Ezequiel Contreras
<[hidden email]> wrote:

> Hi,
>   why there isn't a BitArray or BooleanArray in the collection library?
>   is there a sustitute for that?
>
> thanks
>
> --
> Bernardo E.C.
>
> Sent from a cheap desktop computer in South America.

Reply | Threaded
Open this post in threaded view
|

Re: BitArray and BooleanArray ?

Peter Uhnak
On Thu, Sep 01, 2016 at 07:45:45PM +0800, Ben Coman wrote:
> I don't know the answer but I assume you a looking for a memory
> efficient way of storing booleans.  So perhaps the Bit Field layouts
> discussed here [1] may be of interest considering the recent
> introduction of Slots to Pharo.  Otherwise I verry vaguely remember
> Bitmap used for this somewhere. Sorry I can't be more precise.

Form uses Bitmap to represent graphical stuff. Bitmap itself is a subclass of ArrayedCollection.

Peter