Actor garbage collection

Tony Hannan <>
Thu Nov 4 14:32:35 CET 2010


Hello,

Does an orphaned waiting process get garbage collected? By orphaned I mean
no one references it (no one has its pid) so it will never receive anymore
messages. By waiting I mean it is waiting for a message inside a receive.
For example,

    Wait = fun() -> receive _ -> 0 end end.
    spawn(Wait).

Will that spawned process live and wait forever even though we did not
capture its pid and thus can't send messages to it, or will it be garbage
collected eventually?

Thanks,
Tony


More information about the erlang-questions mailing list