List<Instruction> newInstructions = new ArrayList<>();
List<Instruction> instructions = block.getInstructions();
for (int i = 0; i < instructions.size(); ++i) {
Instruction insn = instructions.get(i);
if (insn instanceof UnwrapArrayInstruction) {
UnwrapArrayInstruction unwrap = (UnwrapArrayInstruction)insn;
instructions.set(i, new EmptyInstruction());
int def = whereDefined(instructions, i, unwrap.getArray());
if (def < 0) {
newInstructions.add(unwrap);
} else {
instructions.add(def + 1, unwrap);
++i;