Boost logo

Boost :

From: William E. Kempf (wekempf_at_[hidden])
Date: 2003-06-30 13:13:02

Philippe A. Bouchard said:
> William E. Kempf wrote:
> [...]
>>> Thanks... but is it possible to obtain the initial address of the
>>> functor object portably, given the current thread object?
>> No, and why would you want to? Especially since it will be a pointer
>> to a _copy_ of the functor?
> Because I would like to access specific information of the newly created
> thread. Being able to match this information with the current thread
> would require you to have some pointer to the class functor.

As already pointed out, to associate data with a thread you use
thread_specific_ptr. BTW, you still have to remember that the functor is
copied, and data passed to/in the functor is not considered part of the
thread in any event.

William E. Kempf

Boost list run by bdawes at, gregod at, cpdaniel at, john at