NextPrevUpTopContentsIndex

14.2.6 Returning a value from another process

Rather than using global variables to pass values between processes, you can use closures instead. For example:

(defun send-with-result (process function)
  (let ((remote-result :none))
    (flet ((resultp ()
             (listp remote-result))
           (run-it ()
             (setq remote-result
                   (multiple-value-list (funcall function)))))
      (mp:process-send process (list #'run-it))
      (mp:process-wait "Waiting for result" #'resultp)
      (values-list remote-result))))

LispWorks User Guide - 21 Jul 2006

NextPrevUpTopContentsIndex