fix merge sort type