Saturday 22 January 2011

#ifdef and #endif in c






Directive #ifdef is very similar to #if except its conditional statement which is identifier instead of a constant expression. Identifier may a macro constant or global identifier. It only checks identifier has been defied or not. It doesn’t care what the value of identifier is. If identifier has been defined then it executes #ifdef body otherwise it executes the body of #else directive.



No comments:

Post a Comment