Fix warnings, add destructuring let1

This commit is contained in:
2023-02-12 12:19:56 -05:00
parent 30964bf4ec
commit 5512ab8804
2 changed files with 268 additions and 251 deletions

View File

@@ -49,13 +49,13 @@ impl Form {
}
pub fn car(&self) -> Option<Rc<Form>> {
match self {
Form::Pair(car, cdr) => Some(Rc::clone(car)),
Form::Pair(car, _cdr) => Some(Rc::clone(car)),
_ => None,
}
}
pub fn cdr(&self) -> Option<Rc<Form>> {
match self {
Form::Pair(car, cdr) => Some(Rc::clone(cdr)),
Form::Pair(_car, cdr) => Some(Rc::clone(cdr)),
_ => None,
}
}