The interpolation doesn’t happen at compile time, it happens while constructing the expression at runtime. The anonymous function is compiled upon first call.
The actual issue is that you’re interpolating the entire x. In other words, $x[1] is equivalent to ($x)[1]. The tuple version works because the compiler is smart enough to figure out that a specific index of an immutable tuple is a constant. The array version doesn’t do that because the array is mutable, so the value at that index might be changed.
If you just want a value in the array to be interpolated, index then interpolate: $(x[1]).