Okay, thanks for the advice, Ben and Tim.
I'll have to rethink it, I guess. There's no obvious/easy place 'here'
to put the result for later retrieval (it would probably have to be
another actor), but maybe with some rethinking it could be refactored
that way.
Ah, but if a future can still be interogated after the actor is dead,
that might work fine. I do have somewhere to store the future and ask
for it (it's just not currently an Actor itself, and not something the
individual Actors know about, the caller context).
Let's see...
Nice, that does work! If you have a future already, you can indeed ask
for it's #value even if the original Actor it was based on has
terminated. That will in fact work perfectly for me. This, that a future
keeps working even after the actor is dead, is an intentional part of
the API, not an accident of implementation likely to change in the, er,
future?
On 5/13/2013 6:10 PM, Ben Langfeld wrote:
> I would suggest you're taking the wrong approach. A better one might be
> "compute the value and then put it *here*". Alternatively, a future may
> survive the actor it was executed in...
>
> Regards,
> Ben Langfeld
>
>
> On 13 May 2013 18:57, Tim Carey-Smith <
g...@spork.in <mailto:
g...@spork.in>>
> wrote:
>
> On May 14, 2013, at 9:44 AM, Jonathan Rochkind <
roch...@jhu.edu
> <mailto:
celluloid-ruby%2Bunsu...@googlegroups.com>.
> <mailto:
celluloid-ruby%2Bunsu...@googlegroups.com>.