$include_dir="/home/hyper-archives/boost-users/include"; include("$include_dir/msg-header.inc") ?>
From: Peter Dimov (pdimov_at_[hidden])
Date: 2006-09-19 16:34:01
Christian Henning wrote:
> Hi there, I know it must be very easy but I cannot figure it out
> myself. Can somehow please take a look at:
> 
> class task
> {
> public:
> 
>   template < class T >
>   void do_it( const T t )
>   {
>      thread_ptr.reset( new boost::thread( boost::bind( (void
> (thread::*)(const T)) &thread::_run
>                                                      , this  )));
>   }
You didn't pass t to _run. Use
    boost::bind( (void (task::*)(const T)) &task::_run, this, t )
> private:
> 
>   template < class T >
>   void _run( const T t ) {}