MAINT: an easier way to make ranges from slices