develooper Front page | perl.ithreads | Postings from August 2002

Re: Thread-Tie-0.01

Thread Previous | Thread Next
From:
Elizabeth Mattijsen
Date:
August 11, 2002 06:38
Subject:
Re: Thread-Tie-0.01
Message ID:
4.2.0.58.20020811153450.0246dea0@mickey.dijkmat.nl
At 02:53 PM 8/11/02 +0200, Arthur Bergman wrote:
>>Aha!  So maybe there the "2 other threads were running" message is coming 
>>from, when you only started one other thread.  Does this shadowy thread 
>>run always, even if you don't have threads::shared ?
>No, the is just a missmg, 2 threads were running.

Eh... which two threads?

$ perl -Mthreads -e 'threads->new( sub { 1 while 1 } )'
A thread exited while 2 other threads were still running.
^^^^^^^^^             ^^^^^^^^^^^^^^^

"A thread" + "2 other threads" = 3.

There is one main thread.  That thread creates another thread.  That makes 
two.  Where is the third?


I think the message is in error since there is no third thread.  Or is 
there?  Or is that taking into account the shared variables thread that may 
or may not be running?


Liz


Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About