Fix large array optimization in `baseDifference`.