3 ms·
If you try to enforce start <= end you get a fallible range constructor which is a usability nightmare, which is why it's not enforced. It has nothing to do wit
by dathinab 6y ago
If you try to enforce start <= end you get a fallible range constructor which is a usability nightmare, which is why it's not enforced. It has nothing to do with `Range` being generic.
I mean consider:
`slice.get(start..end)`
against:
`(start..end).and_then(|range| slice.get(range))`