Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

enum, #define, const

Name: Anonymous 2009-03-28 7:01

For storing integers with bitwise operands inside their declaration, which should I use? Performance wise I think that an enumeration works slightly faster, however what's the standard?

Name: Anonymous 2009-03-28 7:06

>>1
Your choice.

A #define will be recalculated everytime rather than just a look up. This could account for enum being faster..but I would have thought const would have been the same.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List