Ensure list of formals before performing list ops

This commit is contained in:
Justin Ethier 2017-05-15 11:21:13 +00:00
parent 1d36fec61e
commit 7794f3edce

View file

@ -1217,6 +1217,7 @@
(cond
;; TODO: what if fnc has no cont? do we need to handle differently?
((and (ast:lambda? fnc)
(list? formals)
(= (length args) (length formals)))
;(trace:error `(JAE DEBUG beta expand ,exp))
(beta-expansion exp fnc) ; exp