You cannot declare them in the property declarations, but you can instantiate them in the constructor __construct() The array() can be instantiated in the public $w without the new keyword: public $w = array();
public function __construct()
{
$this->y = new ErrorVO();
}