3 ms·
What if you were counting bits instead of bytes?
by amelius 6y ago
What if you were counting bits instead of bytes?
- threatripper 6y agoBits don't appear in array sizes as we use bytes as smallest addressable unit on all relevant platforms.
- amelius 6y agoBut you could imagine a vector of booleans which you can subscript per boolean.
- threatripper 6y agoImaginable: Yes, Relevant: No
- hedora 6y agoCurrent intel 64 bit machines only have 57 bits of address space. The top bits of the pointers are wasted.
- smithza 6y agoI have made a point of using uint16_t, uint32_t, int16_t, int32_t, etc. to be explicit. Some don't like the look, but it is explicit and helpful for me.