remove duplicate array in compiler