/// Every index type to be used with Stash needs to implement this trait
pubtraitIndex{/// Create an index from `usize`.
////// This method should panic if `idx` is out of acceptable range.
fnfrom_usize(idx:usize)->Self;/// Turn this index into `usize`
fninto_usize(self)->usize;}// Auto implement this for types equivalent to `usize`.
impl<T> Index forTwhere
T:From<usize> + Into<usize>,
{fnfrom_usize(idx:usize)->Self{From::from(idx)}fninto_usize(self)->usize{Into::into(self)}}