From: [EMAIL PROTECTED] Operating system: Debian unstable PHP version: 5.0.1 PHP Bug Type: Variables related Bug description: isset/empty() do not take __get() into account
Description: ------------ When calling isset()/empty() on an object which uses overloading (__set()/__get()) the property state is not returned correctly. It just checks for real properties, but not overloaded once. Reproduce code: --------------- class foo { function __get ( $key, $val ) { /* code */ } } $bar = new foo(); $bar->bak = 'bla'; var_dump(isset($bar->bak)); Expected result: ---------------- true Actual result: -------------- false -- Edit bug report at http://bugs.php.net/?id=30736&edit=1 -- Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=30736&r=trysnapshot4 Try a CVS snapshot (php5.0): http://bugs.php.net/fix.php?id=30736&r=trysnapshot50 Try a CVS snapshot (php5.1): http://bugs.php.net/fix.php?id=30736&r=trysnapshot51 Fixed in CVS: http://bugs.php.net/fix.php?id=30736&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=30736&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=30736&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=30736&r=needscript Try newer version: http://bugs.php.net/fix.php?id=30736&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=30736&r=support Expected behavior: http://bugs.php.net/fix.php?id=30736&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=30736&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=30736&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=30736&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=30736&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=30736&r=dst IIS Stability: http://bugs.php.net/fix.php?id=30736&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=30736&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=30736&r=float MySQL Configuration Error: http://bugs.php.net/fix.php?id=30736&r=mysqlcfg