From: ies_clan at hotmail dot com
Operating system: Windows XP SP3
PHP version: 5.3SVN-2009-11-25 (snap)
PHP Bug Type: Class/Object related
Bug description: no notice on undefined property access
Description:
------------
if u try to acccess an property from a class that doesn't exists it throws
a notice, but if u set a value to this property und then u try to access
its ok... but that should ony if there is a __set / __get method in that
class
Reproduce code:
---------------
class test{}
$test = new test();
echo $test->bla;
<-- throws a notice: ok
class test{
public function __set($Key, $Value){...}
public function __get($Key){...}
}
$test = new test();
$test->bla = 'aaa';
echo $test->bla;
<-- throws nothing: ok
class test{}
$test = new test();
$test->bla = 'aaa';
echo $test->bla;
<-- throws nothing: not ok
Expected result:
----------------
first: Notice: Undefined property bla
second:
third: Notice: Undefined property bla
Actual result:
--------------
first: Notice: Undefined property bla
second:
third:
--
Edit bug report at http://bugs.php.net/?id=50295&edit=1
--
Try a snapshot (PHP 5.2):
http://bugs.php.net/fix.php?id=50295&r=trysnapshot52
Try a snapshot (PHP 5.3):
http://bugs.php.net/fix.php?id=50295&r=trysnapshot53
Try a snapshot (PHP 6.0):
http://bugs.php.net/fix.php?id=50295&r=trysnapshot60
Fixed in SVN:
http://bugs.php.net/fix.php?id=50295&r=fixed
Fixed in SVN and need be documented:
http://bugs.php.net/fix.php?id=50295&r=needdocs
Fixed in release:
http://bugs.php.net/fix.php?id=50295&r=alreadyfixed
Need backtrace:
http://bugs.php.net/fix.php?id=50295&r=needtrace
Need Reproduce Script:
http://bugs.php.net/fix.php?id=50295&r=needscript
Try newer version:
http://bugs.php.net/fix.php?id=50295&r=oldversion
Not developer issue:
http://bugs.php.net/fix.php?id=50295&r=support
Expected behavior:
http://bugs.php.net/fix.php?id=50295&r=notwrong
Not enough info:
http://bugs.php.net/fix.php?id=50295&r=notenoughinfo
Submitted twice:
http://bugs.php.net/fix.php?id=50295&r=submittedtwice
register_globals:
http://bugs.php.net/fix.php?id=50295&r=globals
PHP 4 support discontinued: http://bugs.php.net/fix.php?id=50295&r=php4
Daylight Savings: http://bugs.php.net/fix.php?id=50295&r=dst
IIS Stability:
http://bugs.php.net/fix.php?id=50295&r=isapi
Install GNU Sed:
http://bugs.php.net/fix.php?id=50295&r=gnused
Floating point limitations:
http://bugs.php.net/fix.php?id=50295&r=float
No Zend Extensions:
http://bugs.php.net/fix.php?id=50295&r=nozend
MySQL Configuration Error:
http://bugs.php.net/fix.php?id=50295&r=mysqlcfg