1 2 3 4 5 6 7 8
/// `<[T]>::split_at_checked`, but not unstable pub(super) const fn split_at_checked<T>(slice: &[T], mid: usize) -> Option<(&[T], &[T])> { if mid <= slice.len() { Some(slice.split_at(mid)) } else { None } }