Fixed usage of imported namespace.

The use statement imports \ArrayObject as PhpArrayObject so we need to use it here. In other case it will use of undefined constant.
Merge pull request #5507
Merge pull request #5507 in master
Revert "Merge pull request #5507 in master"

This reverts commit 29443bdadc884ef747b37143cf95b68d993f4f9c, reversing
changes made to 17779c3c29680be0a4fa401ca355a7e9de24c6c0.