Bug #52861: unset fails with ArrayObject and deep arrays

When checking to make into a reference write, readwrite are checked but not unset
Merge branch 'PHP-5.3' into PHP-5.4

* PHP-5.3:
  Bug #52861: unset fails with ArrayObject and deep arrays