jammin2night has asked for the wisdom of the Perl Monks concerning the following question:
use strict; use warnings; use threads; my $thread_count = 0; while (1) { threads->new(\&handle_thr +ead,++$thread_count); sleep .1; } sub handle_thread { my $thread_count = shift; threads->self->detach; # so long parent print "You are thread number $thread_count \n"; sleep .2; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Win32 and threads;
by BrowserUk (Patriarch) on Jul 11, 2004 at 00:24 UTC | |
by jammin2night (Initiate) on Jul 11, 2004 at 01:10 UTC | |
by jammin2night (Initiate) on Jul 11, 2004 at 01:22 UTC | |
by jammin2night (Initiate) on Jul 11, 2004 at 15:09 UTC | |
by BrowserUk (Patriarch) on Jul 11, 2004 at 20:07 UTC | |
| |
|
Re: Win32 and threads;
by NetWallah (Canon) on Jul 11, 2004 at 00:08 UTC |