Skip to content
Snippets Groups Projects
Commit 3b849bc0 authored by Philipp Marek's avatar Philipp Marek Committed by lovrolu
Browse files

Avoid duplicate logic in WHEN-LET*

By using an explicit PROGN we can interpolate straight into the LET.
The PROGN shouldn't matter, as the WHEN interferes with DECLAREs anyway.
parent 6bb56b6c
Branches master
No related tags found
No related merge requests found
......@@ -83,11 +83,8 @@ PROGN."
bindings)))
(labels ((bind (bindings body)
(if bindings
`((let (,(car bindings))
(when ,(caar bindings)
,@(bind (cdr bindings) body))))
body)))
`(let (,(car binding-list))
(when ,(caar binding-list)
,@(bind (cdr binding-list) body))))))
`(let (,(car bindings))
(when ,(caar bindings)
,(bind (cdr bindings) body)))
`(progn ,@body))))
(bind binding-list body))))
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment