[A89] Re: Setting bit fields


[Prev][Next][Index][Thread]

[A89] Re: Setting bit fields




At 23:40 2002-03-01, you wrote:

>Why do you need to do an AND and an OR? To set bit 6, you just need:

you answered your own question. the and for clearing, and the or for setting.
its not always (is it even often?) that you only want to clear or only want 
to set bits.
if it isn't just a few, and then its better with bset and bclr anyway.

///Olle




References: