I've just been learning to use threads.pm and
threads::shared.pm.
I spent ages trying to get my script to work until I realised 
that
  use threads;
must come before
  use threads:shared;
This probably should have been obvious from the documentation
in threads.pm which says
  preferably enable threads...as early as possible

I was wondering:
- if threads could work with a simple use threads; or use
  threads::shared;?
  Looking at the code, it appears that they have been modified
so
  that they don't do this. No doubt for some very technical
  reason beyond me (though I'd be grateful if someone could try
  to explain), so if its not feasible, then fair enough.

- if threads.pm and threads::shared.pm could have their
  documentation amended to explicitly mention the order of the
  'use's?
  Given this is Perl (i.e. 'fix what you find if you can'), I'd
  be happy to do this.

- should threads::shared.pm silently fail when there has been no
  use threads;?
  Again looking at the code, this appears to have been
  deliberately designed, so if there's a good reason, then
  ok, though this did give me a lot of grief.

Any thoughts?

Andy Bussey



=====
-------------------------------------------------------
Andy Bussey
[EMAIL PROTECTED]

__________________________________________________
Do You Yahoo!?
Everything you'll ever need on one web page
from News and Sport to Email and Music Charts
http://uk.my.yahoo.com

Reply via email to