Future of Pypy?
Paul Rubin
no.email at nospam.invalid
Mon Feb 23 20:50:24 EST 2015
Chris Angelico <rosuav at gmail.com> writes:
>> What if you want to dynamically construct a callable and send it to
>> another process?
> I'm not sure what that would actually mean. Do you try to construct it
> out of code that already exists in the other process? Are you passing
> actual code to the other process?
I gave an example in a reply to Steven, something like
other_thread_queue.put(lambda x: x*x)
to tell the other thread it is supposed to square something. It
receives a callable and calls it in its own context.
More information about the Python-list
mailing list