Versions in this module Expand all Collapse all v1 v1.0.0 Mar 13, 2024 Changes in this version + var ErrAbortThread = errors.New("abort thread") + var ErrCannotYieldANonrunningThread = errors.New("can not yield a non-running thread") + type Coroutines struct + func New() *Coroutines + func (p *Coroutines) Abort() + func (p *Coroutines) Create(tobj ThreadObj, fn func(me Thread) int) Thread + func (p *Coroutines) CreateAndStart(start bool, tobj ThreadObj, fn func(me Thread) int) Thread + func (p *Coroutines) Current() Thread + func (p *Coroutines) Resume(th Thread) + func (p *Coroutines) Sched(me Thread) + func (p *Coroutines) Sleep(t time.Duration) + func (p *Coroutines) StopIf(filter func(th Thread) bool) + func (p *Coroutines) Yield(me Thread) + type Thread = *threadImpl + type ThreadObj interface