September 8th, 2003, 02:35 PM
question regarding #define statement
i was going through some source code and came accross this define statement #define FL_FROZEN(1<<12) . does this mean that FL_FROZEN can have any value between 1 and 12?
thanks for your time
September 8th, 2003, 02:51 PM
it means FL_FROZEN as the value (binary):
0001 0000 0000 0000 (broken into nibbles for clarity)
as you can see, 1 has been shifted left 12 places, which is exactly what the left shift bitwise operation, <<, is meant to do.