Few more related inconsistencies in current implementation.

class A {

  public int $b;

}

$a = new A;

var_dump($a); // <- prints A::b as NULL

foreach ($a as $val) {

  var_dump($val); // <- prints NULL

}


All similar inconsistencies would be automatically solved with implicit default 
value int(0) and ability to explicitly define property as nullable.


Thanks. Dmitry.

Reply via email to