fixed array index out of bounds when not removing alignment annotation