Fix regression when using pins as array indices