I've written most of the code for process-linking, but I'm having some trouble with the function check-system-messages. When I compile it, I get lots of errors that I don't understand. When I run it, it continues indefinitely and slows my computer to a crawl.
A little explanation about the 'checking-system-messages in process: If a user program tries to do a receive, Erlisp should check for system messages first so the user program doesn't see them. There's a problem with receive calling check-system-messages and also having check-system-messages calling receive because it tends to create infinite loops. My solution was to explicitely check for this circularity, so receive will only call check-system-messages if it was not called by check-system-messages.
I have attached copies of the error messages and the modified source files (process.lisp and messaging.lisp). Hopefully someone has an idea what is going on. I will give this another try in the morning. Just one more day left for SoC, so I'm giving it one final push.
Eric
================== in process.lisp ================== (defun check-system-messages () (setf (slot-value (current-process) 'checking-system-messages) t) (do ((msg (receive-with-matcher (cond-matcher m) ((and (consp m) (eq (first m) 'system)) (rest m)) ((:timeout 0) nil)) (receive-with-matcher (cond-matcher m) ((and (consp m) (eq (first m) 'system)) (rest m)) ((:timeout 0) nil)))) ((not msg) 'done) (when (consp msg) (cond ((and (eq (first msg) 'link-kill) (not (slot-value (current-process) 'dying))) (error "Linked process died. My turn.")) ((and (eq (first msg) 'link-request)) (reverse-link (second msg) :link-type (third msg)))))) (setf (slot-value (current-process) 'checking-system-messages) nil))