APN 20130628 - finally figured the way to understand coroutine based programming was (as always) to sit and actually write some real code. The result is the fiber package. From its introduction:
- This package provides an implementation of "fibers" for Tcl. Fibers, as the term is used in this package, are threads of execution that are co-operatively multitasked and use message passing as their primary means of communication, including channel based I/O.
- Fibers are implemented using Tcl coroutines and are compatible with any Tcl application model provided it runs the Tcl event loop.
- Erlang programmers may find some similarity to that language's process model. That is not just happenstance.
Documentation is at [L1 ]. The project page is at [L2 ]