Minor performance optimization on arrayutils

Some more hidden pearls I didn't really know of: taken from http://stackoverflow.com/a/3471356/347063

I don't know if it's really worth it, but `ArrayUtils::merge` is quite final, and it is used quite a lot, recursively, causing hundreds of calls to `is_array`, and it almost never encounters objects on the way (not in a typical ZF2 app), so I went on and applied it. 

Same applies for the priority queue.