Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!csd4.csd.uwm.edu!cs.utexas.edu!uunet!ficc!peter From: peter@ficc.uu.net (Peter da Silva) Newsgroups: comp.lang.c Subject: Re: Coroutines in C Message-ID: <5914@ficc.uu.net> Date: 29 Aug 89 10:33:07 GMT References: <214@castle.ed.ac.uk> <5899@ficc.uu.net> <10861@smoke.BRL.MIL> Organization: Xenix Support, FICC Lines: 19 In article <10861@smoke.BRL.MIL>, gwyn@smoke.BRL.MIL (Doug Gwyn) writes: > In article <5899@ficc.uu.net> peter@ficc.uu.net (Peter da Silva) writes: > >If [simple setjmp] is used, it should be possible to create > >a fake stack frame and register set in a jmp_buf and tranfer control to it > >using longjmp. > You need separate (non-overlapping) stacks, not just a stack frame. > Otherwise the coroutines will step on each other's . You're right, I should have spelled that out. I sort of assumed that anyone who had been following this discussion would figure that out... but of course someone who was following the discussion wouldn't have asked the question in the first place. I'll try to be clearer in the future and not assume that people will glark stuff like that from context. -- Peter da Silva, *NIX support guy @ Ferranti International Controls Corporation. Biz: peter@ficc.uu.net, +1 713 274 5180. Fun: peter@sugar.hackercorp.com. `-_-' "Just once I'd like to meet an alien menace that isn't immune to bullets" 'U` -- The Brigadier, Dr Who.