/development/std/sequence/index.nct
index.nct
//! Readonly access shared by indexed standard-library sequences.
/// A finite sequence that can expose readonly element borrows.
pub interface Sequence<T> {
pub method &self.len(): usize
pub method &self.get(index: usize): &T?
}
/// Returns the first element borrow without allocating.
pub func first<S: Sequence<T>, T>(values: &S): &T? {
return values.get(0)?
}