]> code.delx.au - gnu-emacs-elpa/commitdiff
Updated README
authorJohn Wiegley <johnw@newartisans.com>
Tue, 19 Jun 2012 00:30:47 +0000 (19:30 -0500)
committerJohn Wiegley <johnw@newartisans.com>
Tue, 19 Jun 2012 00:30:47 +0000 (19:30 -0500)
README.md

index ec7e83ac908dc431b7577a9028170cdbcaec84ce..f7bc852d9b7215599d0b97ea34a35121f5a4de14 100644 (file)
--- a/README.md
+++ b/README.md
@@ -1,6 +1,10 @@
 # emacs-async
 
-Adds the ability to process Lisp concurrently, with a very simple syntax:
+async.el is an exceedingly simple (78 lines of code) module for doing
+asynchronous processing in Emacs, by spawning a child Emacs interpreter to
+execute a lambda function, and calling back when the job is done.
+
+It uses a very simple syntax:
 
     (async-start
        ;; What to do in the child process
@@ -13,9 +17,8 @@ Adds the ability to process Lisp concurrently, with a very simple syntax:
        (lambda (result)
          (message "Async process done, result should be 222: %s" result)))
 
-If you omit the callback function, `async-start` will return a process object
-that you can call `async-get` on when you're ready to wait for the result
-value:
+If you omit the callback function, `async-start` returns a process object that
+you can call `async-get` on when you're ready to wait for the result value:
 
     (let ((proc (async-start
                    ;; What to do in the child process
@@ -23,13 +26,16 @@ value:
                      (message "This is a test")
                      (sleep-for 3)
                      222))))
-        (message "I'm going to do some work here")
-        ;; ....
-        (message "Async process done, result should be 222: %s"
+
+        (message "I'm going to do some work here") ;; ....
+
+        (message "Waiting on async process, result should be 222: %s"
                  (async-get proc)))
 
 If you don't want to use a callback, and you don't care about any return value
-form the child proces, pass the `ignore` symbol as the second argument:
+form the child process, pass the `ignore` symbol as the second argument (if
+you don't, and never call `async-get', it will leave *emacs* process buffers
+hanging around):
 
     (async-start
      (lambda ()