[Tutorial] Directives #if, #else, #elseif, #endif and #error
#5

You two missed the point completely. "MyInfo" is a constant with value 3 (and constants should be written in all upper case), therefore when the preprocessor is done it will be fed to the compiler as:
PHP Code:
if(3
Clearly, 3 isn't smaller than 3, so the compiler translates it to:
PHP Code:
if(false
Therefore giving a compile time error because the corresponding compound block is never (or always) executed.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)