>Hi,
>
>
>"His code is not formally wrong. Bitwise constants like this can be, and are, added together all the time. If I had the K&R C book handy I'd point you to some examples."
>"this book is wrong."
>
>it depends on the defined constants if one has to use BITOR or just can add (+) them.
>
>e.g.
>
>#DEFINE myDef1 0x01
>#DEFINE myDef2 0x02
>#DEFINE myDef3 0x04
>? myDef1+myDef2+myDef3 = BITOR(myDef1,myDef2,myDef3)
>
>#DEFINE myDef4 0x01
>#DEFINE myDef5 0x02
>#DEFINE myDef6 0x03
>? myDef4+myDef5+myDef6 = BITOR(myDef4,myDef5,myDef6)
>
>
>so the bottomline is - if all constants are powers of 2 one can also just add them, if not BITOR has to be used.
>
>Regards
>Christian
Of course!