The IR can store to the first element of an array the same way it stores to the first element of a struct by specifying the base pointer. This commit fixes the pointercast legalization pass to support this.