Adds Array class with test for build

Moves global array helper functions into a namespaced class.
One test is included.
Internal use of global array functions isn't changed.
Taylor raised a concern about the class might not be able to load from everywhere, maybe someone can test this?

For proposal #3528