From:             jon at ijk dot com dot au
Operating system: WinXP SP3
PHP version:      5.2.10
PHP Bug Type:     Scripting Engine problem
Bug description:  define('CONSTANT',0) unexpected results

Description:
------------
Unexpected output from using define('CONSTANT',0) specifically

Reproduce code:
---------------
define('TESTER',0);

if(TESTER=='me'){echo 'yes1';}
else{echo 'no1';}
if(TESTER==0){echo 'yes2';}
else{echo 'no2';}
if(TESTER==1){echo 'yes3';}
else{echo 'no3';}

Expected result:
----------------
no1yes2no3

Actual result:
--------------
yes1yes2no3

-- 
Edit bug report at http://bugs.php.net/?id=49434&edit=1
-- 
Try a snapshot (PHP 5.2):            
http://bugs.php.net/fix.php?id=49434&r=trysnapshot52
Try a snapshot (PHP 5.3):            
http://bugs.php.net/fix.php?id=49434&r=trysnapshot53
Try a snapshot (PHP 6.0):            
http://bugs.php.net/fix.php?id=49434&r=trysnapshot60
Fixed in SVN:                        
http://bugs.php.net/fix.php?id=49434&r=fixed
Fixed in SVN and need be documented: 
http://bugs.php.net/fix.php?id=49434&r=needdocs
Fixed in release:                    
http://bugs.php.net/fix.php?id=49434&r=alreadyfixed
Need backtrace:                      
http://bugs.php.net/fix.php?id=49434&r=needtrace
Need Reproduce Script:               
http://bugs.php.net/fix.php?id=49434&r=needscript
Try newer version:                   
http://bugs.php.net/fix.php?id=49434&r=oldversion
Not developer issue:                 
http://bugs.php.net/fix.php?id=49434&r=support
Expected behavior:                   
http://bugs.php.net/fix.php?id=49434&r=notwrong
Not enough info:                     
http://bugs.php.net/fix.php?id=49434&r=notenoughinfo
Submitted twice:                     
http://bugs.php.net/fix.php?id=49434&r=submittedtwice
register_globals:                    
http://bugs.php.net/fix.php?id=49434&r=globals
PHP 4 support discontinued:          http://bugs.php.net/fix.php?id=49434&r=php4
Daylight Savings:                    http://bugs.php.net/fix.php?id=49434&r=dst
IIS Stability:                       
http://bugs.php.net/fix.php?id=49434&r=isapi
Install GNU Sed:                     
http://bugs.php.net/fix.php?id=49434&r=gnused
Floating point limitations:          
http://bugs.php.net/fix.php?id=49434&r=float
No Zend Extensions:                  
http://bugs.php.net/fix.php?id=49434&r=nozend
MySQL Configuration Error:           
http://bugs.php.net/fix.php?id=49434&r=mysqlcfg

Reply via email to