diff --git a/core/actor.lisp b/core/actor.lisp index 5f849ac..6ff2809 100644 --- a/core/actor.lisp +++ b/core/actor.lisp @@ -68,12 +68,10 @@ (defgeneric send (tsk msg) (:method ((tsk async:mailbox) msg) - ;(util:lgi msg) (async:snd tsk msg))) (defun become (bhv) - (set-bhv *self* bhv) - bhv) + (set-bhv *self* bhv)) ;;;; handling restartable tasks @@ -82,13 +80,13 @@ (multiple-value-bind (msg ok) (async:try-rcv tsk) (if ok (if (eq (content msg) +quit-message+) - (progn (async:set-status tsk :stopped) nil) + (async:set-status tsk :stopped) (progn (async:set-status tsk :running) (let ((*self* tsk)) (funcall bhv msg) (ac-loop tsk (async:behavior tsk))))) - (progn (async:set-status tsk :suspended) bhv)))) + (async:set-status tsk :suspended)))) (defmethod send ((tsk async:restartable-task) msg) (let ((status (async:get-status tsk))) diff --git a/core/core.lisp b/core/core.lisp index ee63d86..fbfb4a4 100644 --- a/core/core.lisp +++ b/core/core.lisp @@ -100,8 +100,7 @@ (dolist (ctx (alx:hash-table-values (services *root*))) (funcall (config:shutdown (config ctx)) ctx)) ;(actor:stop *root*) - (async:finish) -) + (async:finish)) (defun add-action (ctx pat hdlr) (let* ((acts (actions ctx))