1 \input texinfo @c -*-texinfo-*-
3 @setfilename 8sync.info
7 Copyright @copyright{} 2015 Christopher Allan Webber @email{cwebber@@dustycloud.org}
11 Permission is granted to copy, distribute and/or modify this document
12 under the terms of the GNU Free Documentation License, Version 1.3
13 or any later version published by the Free Software Foundation;
14 with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.
15 A copy of the license is included in the section entitled ``GNU
16 Free Documentation License''.
18 A copy of the license is also available from the Free Software
19 Foundation Web site at @url{http://www.gnu.org/licenses/fdl.html}.
21 Altenately, this document is also available under the Lesser General
22 Public License, version 3 or later, as published by the Free Software
25 A copy of the license is also available from the Free Software
26 Foundation Web site at @url{http://www.gnu.org/licenses/lgpl.html}.
33 @subtitle Using 8sync, an asynchronous event loop for Guile
34 @author Christopher Allan Webber
36 @vskip 0pt plus 1filll
40 @c Output the table of the contents at the beginning.
50 @c Generate the nodes for this menu with `C-c C-u C-m'.
53 @c Update all node entries with `C-c C-u C-n'.
54 @c Insert new nodes with `C-c C-c n'.
59 * Copying This Manual::
66 8sync's goal is to make asynchronous programming easy. If you've worked
67 with most other asynchronous programming environments, you know that it
68 generally isn't. Usually asynchronous programming involves entering
69 some sort of ``callback hell''. Some nicer environments like Asyncio
70 for Python provide coroutines, but even these require a lot of work to
73 Coding in 8sync, on the other hand, looks almost entirely like coding
74 anywhere else. This is because 8sync makes great use of a cool feature
75 in Guile called ``delimited continuations''. Because of this, you can
76 invoke your asynchronous code with a small wrapper around it, and that
77 code will pop off to complete whatever other task it needs to do, and
78 resume your function when it's ready passing back the appropriate value.
80 Now that's pretty cool!
82 @node Acknowledgements
83 @chapter Acknowledgements
85 8sync has a number of inspirations:
89 @uref{https://docs.python.org/3.5/library/asyncio.html, asyncio}
90 for Python provides a nice asynchronous programming environment, and
91 makes great use of coroutines. It's a bit more difficult to work with
92 than 8sync (or so thinks the author) because you have to ``line up''
96 @uref{http://dthompson.us/pages/software/sly.html, Sly}
97 by David Thompson is an awesome functional reactive game programming
98 library for Guile. If you want to write graphical games, Sly is almost
99 certainly a better choice than 8sync. Thanks to David for being very
100 patient in explaining tough concepts; experience on hacking Sly greatly
101 informed 8sync's development. (Check out Sly, it rocks!)
104 Reading @uref{https://mitpress.mit.edu/sicp/, SICP}, particularly
105 @uref{https://mitpress.mit.edu/sicp/full-text/book/book-Z-H-19.html#%_chap_3,
106 Chapter 3's writings on concurrent systems},
107 greatly informed 8sync's design.
110 Finally, @uref{https://docs.python.org/3.5/library/asyncio.html, XUDD}
111 was an earlier ``research project'' that preceeded 8sync. It attempted
112 to bring an actor model system to Python. However, the author
113 eventually grew frustrated with some of Python's limitations, fell in
114 love with Guile, and well... now we have 8sync, which is much more
119 The motivation to build 8sync came out of
120 @uref{https://lists.gnu.org/archive/html/guile-devel/2015-10/msg00015.html, a conversation}
121 at the FSF 30th party between Mark Weaver, David Thompson, Andrew
122 Engelbrecht, and Christopher Allan Webber over how to build
123 an asynchronous event loop for Guile and just what would be needed.
125 A little over a month after that, hacking on 8sync began!
128 @node Copying This Manual
129 @appendix Copying This Manual
131 This manual is licensed under the GNU Free Documentation License, with
132 no invariant sections. At your option, it is also available under the
133 GNU Lesser General Public License, as published by the Free Software
134 Foundation, version 3 or any later version.
137 * GNU Free Documentation License:: License for copying this manual.
140 @c Get fdl.texi from http://www.gnu.org/licenses/fdl.html
141 @node GNU Free Documentation License
142 @section GNU Free Documentation License
154 @c 8sync.texi ends here