On Fri, 15 Apr 2005, Nigel Sandever wrote: > I struck me a while back that there is a contradiction in idea of a shared, > 'my' variable. > > I want to say lexical, but a var declared with 'our' is in some sense lexical.
Shared-between-threads and shared-between-scopes are orthogonal properties; using "our" or "my" controls access by lexical scope; something else is needed to control access by thread, and ":shared" is as good as anything. The only exception to this orthogonality is that anything within a closure is not shared between threads -- but of course, that is only sensible because it is not even shared between multiple closures *within* a thread. -Martin