Safely calling lisp lambda function from C?

2015-09-08 Thread bruce li
Hi, I'm writing a wrapper for a game engine that involves a few callbacks. I wrap the callback in a C function so that I can pass in lambdas as callbacks. Here is how the code looks like: cl_object callback_wrapper(cl_object lambda, cl_object ...) { cl_funcall(2, lambda, some_params); } It wo

Re: Swank server dies with any error in REPL

2015-09-04 Thread bruce li
t's a case, you could do something, what toplevel does (setting > handlers etc), or set si::*break-level* to 1 and call tpl: > > (let ((si::*break-level* 1)) (si::tpl)) > > this should spawn toplevel console and won't exit. If you want to set > proper handler consult src/ls

Re: Swank server dies with any error in REPL

2015-09-01 Thread bruce li
mething, what toplevel does (setting > handlers etc), or set si::*break-level* to 1 and call tpl: > > (let ((si::*break-level* 1)) (si::tpl)) > > this should spawn toplevel console and won't exit. If you want to set > proper handler consult src/lsp/tpl.lsp file in ECL sourcecode

Swank server dies with any error in REPL

2015-09-01 Thread bruce li
Hi, there, I'm pretty new to ECL. I'm currently considering embedding ECL in a game engine. When I interactively interrupt the program and drop into the repl, I load up swank with quicklisp and create swank server with (swank:create-server :port 4005). I can connect to it from SLIME. But any error