Closed john-science closed 9 years ago
Here is some example implementation code for exit:
elif ast[0] == 'exit':
return eval_exit(ast, env)
def eval_exit(ast, env):
assert_exp_length(ast, 1)
exit()
There is a problem with the string implementation:
(raise "hi")
! LispError:"hi" not in the environment.
Some part of this will have to be implemented in Python. Perhaps a syntax something like:
This could be implemented in lisp, if we have an exit statement: