Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re^2: is_joinable question

by anaconda_wly (Scribe)
on Jun 04, 2013 at 06:03 UTC ( #1036903=note: print w/ replies, xml ) Need Help??


in reply to Re: is_joinable question
in thread is_joinable question

example you give works, but I didn't understand difference between threads->list( threads::joinable ) and is_joinable yet

while( threads->list ) { for my $joinable ( threads->list( threads::joinable ) ) { $joinable->join; } }


Comment on Re^2: is_joinable question
Download Code
Re^3: is_joinable question
by MidLifeXis (Monsignor) on Jun 04, 2013 at 13:06 UTC

    I can ask my kids "is mom home yet?" and get a yes or no answer. I can also ask them to wait outside until their mom gets back. The first is like is_joinable, the second is like join. One gets a yes or no answer, the other blocks until it is done.

    Update: Ignore me. Didn't read the question completely.

    --MidLifeXis

Re^3: is_joinable question
by Anonymous Monk on Jun 05, 2013 at 06:03 UTC

    example you give works, but I didn't understand difference between threads->list( threads::joinable ) and is_joinable yet

    Ok, and then what happened? Do you have a question? What do you understand?

    Do you understand the difference between a while loop and an if statement?

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1036903]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (6)
As of 2015-07-07 03:45 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (87 votes), past polls