macro_rules! push {
[ $llist:expr; $item:expr, $place:ident ] => { ... };
}Expand description
The push! macro prepend item to stored in place by creating a new cons cell using the llist. Please note that, unlike Common Lisp, push! does not return the list.
use llist::{LList, dolist, list, push};
let llist = LList::new();
let mut lst = list![llist; 100];
push!(llist; 90, lst);
push!(llist; 80, lst);
dolist!((i &lst) {
println!("Element: {}", i.car());
});