Array support

This includes the entire array support including the part 1 that was already committed in the array_type branch.