From: hongnk at hotmail dot com Operating system: Win2k PHP version: 5.0.0b2 (beta2) PHP Bug Type: Zend Engine 2 problem Bug description: Object properties created redundantly
Description: ------------ Whenever a variable is refered anywhere inside a class under the form $this->varname, it is automatically created in class instances. Reproduce code: --------------- class A { function NotAConstructor(){ if(isset($this->x)){ //just for demo } } } $t=new A(); var_dump($t); Expected result: ---------------- object(a)#1 (0) { } Actual result: -------------- object(a)#1 (1) { ["x"]=> NULL } -- Edit bug report at http://bugs.php.net/?id=26182&edit=1 -- Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=26182&r=trysnapshot4 Try a CVS snapshot (php5): http://bugs.php.net/fix.php?id=26182&r=trysnapshot5 Fixed in CVS: http://bugs.php.net/fix.php?id=26182&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=26182&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=26182&r=needtrace Try newer version: http://bugs.php.net/fix.php?id=26182&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=26182&r=support Expected behavior: http://bugs.php.net/fix.php?id=26182&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=26182&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=26182&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=26182&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=26182&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=26182&r=dst IIS Stability: http://bugs.php.net/fix.php?id=26182&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=26182&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=26182&r=float