coffee: Fix exception on literal empty list
[jackhill/mal.git] / coffee / step7_quote.coffee
index 36ffbfe..1304c8f 100644 (file)
@@ -36,6 +36,7 @@ EVAL = (ast, env) ->
  loop
   #console.log "EVAL:", printer._pr_str ast
   if !types._list_Q ast then return eval_ast ast, env
+  if ast.length == 0 then return ast
 
   # apply list
   [a0, a1, a2, a3] = ast