Question About Thread-Safety of boost::bind Library

When I see placeholder variables ("_1", "_2", etc.) in Boost.Bind, the first thing that comes to my mind is, what are the effects of this on reentrancy and thread-safety in the Boost.Bind library? What must one watch out for when attempting to use the Boost.Bind library in a multithreaded program? Is it possible to make effective use of the Boost.Bind library while ignoring the ("_1", "_2", etc.) placeholder variables? The "Proposal to Add an Enhanced Binder to the Library Technical Report" of 2003-02-28 doesn't address these concerns, so I'm asking them here. Thanks. This message and any attachments (the "message") is intended solely for the addressees and is confidential. If you receive this message in error, please delete it and immediately notify the sender. Any use not in accord with its purpose, any dissemination or disclosure, either whole or partial, is prohibited except formal approval. The internet can not guarantee the integrity of this message. BNP PARIBAS (and its subsidiaries) shall (will) not therefore be liable for the message if modified. --------------------------------------------- Ce message et toutes les pieces jointes (ci-apres le "message") sont etablis a l'intention exclusive de ses destinataires et sont confidentiels. Si vous recevez ce message par erreur, merci de le detruire et d'en avertir immediatement l'expediteur. Toute utilisation de ce message non conforme a sa destination, toute diffusion ou toute publication, totale ou partielle, est interdite, sauf autorisation expresse. L'internet ne permettant pas d'assurer l'integrite de ce message, BNP PARIBAS (et ses filiales) decline(nt) toute responsabilite au titre de ce message, dans l'hypothese ou il aurait ete modifie.

john.davison@americas.bnpparibas.com wrote:
When I see placeholder variables ("_1", "_2", etc.) in Boost.Bind, the first thing that comes to my mind is, what are the effects of this on reentrancy and thread-safety in the Boost.Bind library? What must one watch out for when attempting to use the Boost.Bind library in a multithreaded program?
I'm not sure what your concerns are. Every bind expression that uses placeholder variables makes its own copies of them, and even if it didn't, placeholders have no state.
participants (2)
-
john.davison@americas.bnpparibas.com
-
Peter Dimov