field_iterator 0.1.0

A derivable trait for iterating over the fields of a struct.
Documentation
1
2
3
4
5
pub use field_iterator_derive::Iterable;
pub trait Iterable {
    fn iter<'a>(&'a self) -> std::vec::IntoIter<(&'static str, &'a dyn std::any::Any)>;
    fn iter_mut<'a>(&'a mut self) -> std::vec::IntoIter<(&'static str, &'a mut dyn std::any::Any)>;
}