fix tuple cmp method