Simplify uniq() to use only one uniquing function.