Boost logo

Boost Users :

Subject: Re: [Boost-users] Compiler Error With boost::bind and boost::signals
From: Peter Barker (newbarker_at_[hidden])
Date: 2009-02-02 07:14:27


On Mon, Feb 2, 2009 at 12:05 PM, KERSAM <kersam_at_[hidden]> wrote:
>
> No, that's not working....
> I still got the same error.
> Any other ideas?

I'm using Boost 1.35.0 and Visual Studio 2003 and Steve's suggestion
worked fine. There was a remaining benign warning C4675 about argument
dependent lookup.

Here's the code that compiled:

#include<boost/bind.hpp>
#include<boost/signals.hpp>

class MyBoostTest {
public:
       void testFunction(int x, int y) {}
};

void doConnect() {
       boost::signal2<void, int, int> signal;
       signal.connect(boost::bind<void>(&MyBoostTest::testFunction, new
MyBoostTest, _1,_2));
}

Regards,

Pete


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