From: Christopher Allan Webber Date: Wed, 27 Apr 2016 22:08:34 +0000 (-0500) Subject: actors: Handle messages/coroutines in want of reply and errors. X-Git-Tag: v0.2.0~17 X-Git-Url: https://jxself.org/git/?a=commitdiff_plain;ds=sidebyside;h=413f6d981a7c4e11f2270c7bd52527d3e5a3a2c1;hp=413f6d981a7c4e11f2270c7bd52527d3e5a3a2c1;p=8sync.git actors: Handle messages/coroutines in want of reply and errors. If we call another method and we're "waiting" on a reply, and an error happens in the other function so that it can't continue, that shouldn't leave our coroutine hanging around in the waiting-coroutines hashmap forever. Instead, we raise it and throw an error warning about that. (More ideally, we'd like to raise this inside of the send-message type methods but that seems to cause a SIGABRT. Yikes!) * 8sync/systems/actors.scm (hive-reply-with-error): New method. (hive-process-message): Update call-catching-coroutine to reply with an eror if an uncaught exception happens. Update resume-waiting-coroutine to recognize whether the message has a '*reply* action or not. If not, remove the coroutine (we'll never get a reply) and throw an error. ---