pub trait PointerFamily<'a> {
    type Pointer<T: 'a>: Deref<Target = T> + Clone;
}
Expand description

Abstraction over smart pointers.

Used so to make the indexical data structures generic with respect to choice of Rc or Arc (or your own clonable smart pointer!).

Required Associated Types§

source

type Pointer<T: 'a>: Deref<Target = T> + Clone

Pointer type for a given family.

Object Safety§

This trait is not object safe.

Implementors§

source§

impl<'a> PointerFamily<'a> for ArcFamily

§

type Pointer<T: 'a> = Arc<T>

source§

impl<'a> PointerFamily<'a> for RcFamily

§

type Pointer<T: 'a> = Rc<T>

source§

impl<'a> PointerFamily<'a> for RefFamily<'a>

§

type Pointer<T: 'a> = &'a T