Can somebody explain to me why PHP does not report a warning or error when accessing a property of a empty object (var is not assigned)?
For example:
$oMyObject->test = 'hello world'; // $oMyObject is not assigned but no warning or error
When i do this, it produces an error:
$oMyObject->test(); // Error: Calling function on non-object
Version info:
Windows XP
XAMPP Windows Version 1.7.0
Apache/2.2.11 (Win32)
PHP 5.2.8
Zend Engine v2.2.0, Copyright (c) 1998-2008 Zend Technologies
with Xdebug v2.0.4, Copyright (c) 2002-2008, by Derick Rethans
Why? Tried to set error_reporting( E_ALL ) but still no error or warning.