Boost logo

Boost Users :

From: Mike Feldmeier (pooky_bunny_at_[hidden])
Date: 2004-05-24 15:21:40


I've seen variations of this come up in this newsgroup and elsewhere, but I
have yet to find an answer that works for me.

class threaded_manager
{
    public:
        void start(void);
};

threaded_manager mgr;

boost::thread(boost::bind(&threaded_manager::start, &mgr));

This consistently produces the linking error:

converter.obj : error LNK2019: unresolved external symbol
"__declspec(dllimport) public: __thiscall boost::thread::thread(class
boost::function0<void,class _STL::allocator<class boost::function_base> >
const &)"
(__imp_??0thread_at_boost@@QAE_at_ABV?$function0_at_XV?$allocator_at_Vfunction_base_at_boos
t@@@_STL@@@1@@Z) referenced in function "public: void __thiscall
mytest::test::converter::run(void)" (?run_at_converter@test_at_mytest@@QAEXXZ)

Separating the two boost functions on to separate lines works fine:

boost::bind(&threaded_manager::start, &mgr);
boost::thread();

..which indicates to me that bind is returning an object that is not
compatible with thread, but I've seen multiple examples of just this type of
call.

This is probably something simple, my two days of experience with Boost just
doesn't appear to be sufficient. What in the world am I doing wrong?

Thanks,
Mike

_________________________________________________________________
Stop worrying about overloading your inbox - get MSN Hotmail Extra Storage!
http://join.msn.click-url.com/go/onm00200362ave/direct/01/


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net