fix bug in ordering of right slices