2010/1/5 Roger Pack <rogerpack2005 / gmail.com>:
>> I don't think it gains you anything: in a fork the child process has a
>> completely separate address space, so all variables are independent from
>> the parent.
>>
>> However in threads you may wish explicitly to copy a value, because it
>> can change in the other thread. Especially;
>
> right it doesn't gain anything, except continuity between threading
> versus forking.  ¨Βκυστ συςπςισενε το ξοαμμοιτ
How would that proposed change make switching between threads and
processes easier?  First of all exchanging the function call is not
sufficient.  You also need to change the communication means between
different threads / processes.  The only way to make threads and
processes interchangeable is to create a framework which abstracts all
these aspects away - which I believe has been done already.  For that
the small difference between fork and Thread.new is insignificant.  If
you think about it fork and Thread.new might be far less
interchangeable than you thought.  The only commonality is that they
create concurrent activity.

Kind regards

robert

-- 
remember.guy do |as, often| as.you_can - without end
http://blog.rubybestpractices.com/