it’s time for a stupid idea again.
I love @:enum abstacts. But what I do not appriciate is the concept of having very often a small list of enums (let’s say four) that is represented with a 32-bit/ 64 integer.
I then have experimented with an @:enum abstract that has an underlying type of a vector storing booleans.
The vectors are set up to store only two booleans, so we have a four-bit-constellation.
This construction works as you can see here:
But I ask myself, if there actually is an advantage of memory usage and/ or performance or if the advantages are eaten up by the overhead.
Or can the same purpose could be achieved easier with the class Bytes?
What do you think?