Simplify index creation code further

- Normalize the range index to an array internally to minimize special cases
- Build up all index bits in an array & join them