Use constants with Perl threads
threads::shared
doesn't allow to share constants between threads.
From perldoc:
"When a constant is used in an expression, Perl replaces it with its value at compile time(...)" so there is no need to share it at run time!
精彩评论