Be aware that Perl's ithreads are quite different from Python's threads, and much, harder to use well.
Python's threads are "user threads" whereas Perl's are "kernel threads". Google for many good descriptions of the difference and the pros and cons of both.
... my perl told me that I need 5.8.6 ...
Tell "your perl" it's wrong. Perl has had threads since 5.6.1 and usable threads since 5.8.4, though it is correct that if you are going to use threads, it would be a good idea to get the latest version.
why perl do not have predefined thread as in
python.
You have to do from threading import Thread to use threads in Python and use threads; to use threads in Perl. What difference?
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
Lingua non convalesco, consenesco et abolesco. -- Rule 1 has a caveat! -- Who broke the cabal?
"Science is about questioning the status quo. Questioning authority".
The "good enough" maybe good enough for the now, and perfection maybe unobtainable, but that should not preclude us from striving for perfection, when time, circumstance or desire allow.
| [reply] [d/l] [select] |
but my
perl told me that I need 5.8.6 to make it works
Are you sure? What was the exact error message?
why perl do not have predefined thread as in
python
Hmm, I'm guessing you mean your perl wasn't built with threads (perl -V:useithreads returns useithreads='undef';)?
I think python can also be built without thread support. Just compile another one.
| MJD says "you can't just make shit up and expect the computer to know what you mean, retardo!" | | I run a Win32 PPM repository for perl 5.6.x and 5.8.x -- I take requests (README). | | ** The third rule of perl club is a statement of fact: pod is sexy. |
| [reply] [d/l] [select] |
Enter on your command prompt/shell
# perl -V
The V is capital.
The results will be how your perl was compiled
If you see something like this
usethreads=undef use5005threads=undef useithreads=undef usemultiplicit
+y=undef
Then you have to recompile your perl with threads enable.
``The wise man doesn't give the right answers,
he poses the right questions.''
TIMTOWTDI
| [reply] [d/l] [select] |
Yes , usethreads=undef use5005threads=undef useithreads=undef usemultiplicity=undef my perl is not compiled with thread, so I need re-compile it to make it
usable,
thanks everyone,
whatluo
| [reply] |
perl told me that I need 5.8.6 to make it works
It's very unlinkely that this error is related to threads. Are you sure the problem is not in another module? possible a recent one from CPAN?
Try greping your installed perl packages for "5.008006" or "5.8.6" to see which one has that requirement. | [reply] |
| [reply] |