KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I am using boost::signal in a native C++ class, and I now I am writing a .NET wrapper in C++/CLI, so that I can expose the native C++ callbacks as .NET events. When I try to use boost::bind to take the address of a member function of my managed class, I get compiler error 3374, saying I cannot take the address of a member function unless I am creating a delegate instance. Does anyone know how to bind a member function of a managed class using boost::bind? For clarification, the following sample code causes Compiler Error 3374: #include <boost/bind.hpp> public ref class Managed { public: Managed() { boost::bind(&Managed::OnSomeEvent, this); } void OnSomeEvent(void) { } };
Tags (comma-separated)
Save Edits
Cancel