in reply to Bit order in bytes

It has a lot to do with human nomenclature ... do they number the bits from left-to-right (0=MSB), or from right-to-left? Then, entirely separately from this, do they store a multi-byte number high-byte-first or low-byte-first? Finally, how does your programming-tool of choice do it? There are no "right" answers. When you are doing bit-twiddling, you have to think of all these things, and it is highly machine-specific. Documentation and project designs need to explicitly spell-out all of these things, right there on the front page, and it should also be summarized in documentation within the source code.

Replies are listed 'Best First'.
Re^2: Bit order in bytes
by geoffleach (Scribe) on Dec 10, 2013 at 18:36 UTC
    With respect to doc, would it surprise you to hear that there's no mention? No? Me neither.

    That said, someone is messing with my int, reversing the order of the bits per-byte. What I conclude from your reply is that I'll just have to live with it. Sigh! And thanks.