Re: RFC 178 (v1) Lightweight Threads

2000-09-03 Thread Steven W McDougall
There is a fundemental issue on how values are passed between threads. Does the value leave one thread and enter the other or are they shared. The idea tossed around -internals was that a value that crosses a thread boundary would have a wrapper/proxy attached to handle the mediation. The

Re: RFC 178 (v1) Lightweight Threads

2000-09-02 Thread Chaim Frenkel
"SWM" == Steven W McDougall [EMAIL PROTECTED] writes: Not unless it is so declared my $a :shared. SWM Sure it is. SWM Here are some more examples. SWM Example 1: Passing a reference to a block-scoped lexical into a thread. Depends on how locking/threading is designed. There is a fundemental

Re: RFC 178 (v1) Lightweight Threads

2000-08-31 Thread Steven W McDougall
The more interesting case is this: #!/my/path/to/perl sub foo_generator { my $a = shift; sub { print $a++ } } my $foo = foo_generator(1); $foo-(); Thread-new($foo); Is $a shared between threads or not? $a is shared between threads. The anonymous subroutine is a