fix trunc_slice when there's only one segment