|
Boost : |
Subject: Re: [boost] [assign] operators+= and -= for set/reset bits in std::bitset
From: Robert Jones (robertgbjones_at_[hidden])
Date: 2010-12-07 04:24:06
On Tue, Dec 7, 2010 at 9:11 AM, Winkler, Bernd <
Bernd.Winkler_at_[hidden]> wrote:
>
> Bitset<8> flag_pattern; //initialisation to "00000000"
> flag_pattern += 1,3,4,5; //set bits at indices 1,3,4,5 to true: 01011100
>
Doesn't the interpretation of that depend on the endianness of your
architechture?
I would have expected
Bitset<8> flag_pattern; //initialisation to "00000000"
> flag_pattern += 1,3,4,5; //set bits at indices 1,3,4,5 to true: 00111010
>
- Rob.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk