As for caveats with regard to threading
It's a normal Perl scalar. It will get cloned on thread creation like every other. Each thread will be accessing its own copy of it. No problem.
Update: s/a different/its own/
In reply to Re^2: XS: exposing C++ library constant as package variable
by ikegami
in thread XS: exposing C++ library constant as package variable
by wisnij
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |