-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Labels
bugSomething isn't workingSomething isn't workinggood first issueGood for newcomersGood for newcomers
Description
Use static_cast to resolve this problem
Delegates/cpp/Platform.Delegates/Platform.Delegates.Delegate.h
Lines 35 to 36 in 77ae748
| Delegate(std::shared_ptr<Class> object, ReturnType(Class:: *member)(Args...)) | |
| : Delegate(std::make_shared<MemberMethod<Class>>(std::move(object), member)) { } |
struct base
{
void foo() { std::cout << "foo"; }
};
struct derived : public base {};
auto object = std::make_shared<derived>();
auto delegate = Platform::Delegates::Delegate((std::shared_ptr<base>)object, &derived::foo);
delegate();Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workinggood first issueGood for newcomersGood for newcomers