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

RE: Thread::Use - use a module inside a thread only

Thread Previous | Thread Next
From:
Nick Ing-Simmons
Date:
August 1, 2002 00:44
Subject:
RE: Thread::Use - use a module inside a thread only
Message ID:
20020801074429.1313.2@bactrian.elixent.com
Paul Green <Paul.Green@stratus.com> writes:
>Maybe an I/O layer should be required to explicitly declare itself
>thread-safe?  

The IO layer's ->Dup method is free to "fail" in any way it chooses
when asked to do a clone-for-thread.

>(Or whatever thread-xxx term I mean here).  Any layer not
>declared thread-safe should be removed when a new thread is created. (And
>now perl can print a warning, since it is doing something you might not like
>& might not realize is happening).

It may make sense eventually to add a flag bit and do the fail-ing in perlio.c 
but until we see a "pattern" in types of problem it is better 
if layer's own code decides what to do.

-- 
Nick Ing-Simmons
http://www.ni-s.u-net.com/


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