<br><br><div><span class="gmail_quote">On 17/03/2008, <b class="gmail_sendername">Stefan Blixt</b> <<a href="mailto:stefan.blixt@gmail.com">stefan.blixt@gmail.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Doesn't this effectively happen if the method executing in the shred exits? LIke this:</blockquote><div><br><br>Yes, it does, and that's one way. Another is to use the "Machine" device. For example "Machine.remove(15);" will remove the shred with id 15 (see chuck --status for id numbers). Note that that spork operations will return the id of the new shred as a int.<br>
<br>Also possible;<br>--------------------------------------------------<br>//create a shred reference with a name<br>Shred my_shred;<br><br>//assign a bit of running code to it<br>spork ~ my_fun() @=> my_shred;<br><br>
//other stuff happens<br>5::minute => now;<br><br>//this is really quite readable compared to other options.<br>my_shred.exit();<br></div>-----------------------------------------<br><br>Hope that helps,<br>Kas.<br></div>