You should never get an error redefining a #define, a typedef yes, if you do the compilers broken.
some compilers will generate an error using #undef on something that was never #define'd so you should always guard it.
Unfortunately theres no easy way of telling the difference between a typedef and a #define.
You might get an error on the use of the redefined #define, but thats not because of the redefine itself.
I like to redefine NULL on projects i know are going crossplatform, then i know what its going to be, theres only a few rare systems where NULL isn't 0, but i've seen enough uses of (void*) 0 to do it, plus it doesn't hurt anything.
using null as an arrayname though is asking for trouble
|