visitor 0.2.1

A generic library to easily visit elements of a structure and perform an action on each one
Documentation
1
2
3
4
5
6
7
8
9
10
11
#[cfg(test)]
mod test;

pub trait Visitor<T>{
	type Error;
	fn visit(&mut self, data: T) -> Result<(), Self::Error>;
}

pub trait Visit<T>{
	fn visit<V: Visitor<T>>(&self, f: &mut V) -> Result<(),V::Error>;
}