[chuck] returning values when sporking

Matthew Shanley matthewshanley at littlesecretsrecords.com
Thu Apr 21 21:57:22 EDT 2005

Hash: SHA1

Hi all,

I'm new to the practice of forking, and experimenting with it (well
sporking) in chuck. I'm making a call along the lines of:

spork ~ sporkFun(arguments) => int value;

to a function:

fun int sporkFun(arguments) {returs something in here}

As I'm sure most of you know quite well, value doesn't get the return
value from the function called by the spork, but rather the shred ID.
That makes sense just fine and I can see lots of value in that. What I'm
wondering is if there's a way for the child shred to return values to
the parent, or as a wider question, for them to communicate in any way.
I've figured out that global variables can be accessed both by parent
and child, so I guess using those as flags is one way to go. Any other
ideas? I think this should all be clear, but I can post code if that
would help.

eagerly awaiting arrays, but not envying the work by ge and the rest to
bring them to us,


- --
Matthew Shanley
little secrets records and stuff
E-mail: matthewshanley at littlesecretsrecords.com

GnuPG Public Key ID: 0x4DA4915C
Version: GnuPG v1.2.4 (Darwin)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org


More information about the chuck mailing list