Setting the locale before sorting ensures a stable sorting order

c_sort(x, ...)

Arguments

x

for sort an R object with a class or a numeric, complex, character or logical vector. For sort.int, a numeric, complex, character or logical vector, or a factor.

...

arguments to be passed to or from methods or (for the default methods and objects without a class) to sort.int.