R
Ray Tayek
hi, trying to make an array of function pointers to make delegates with.
but the compiler does not like: void (Foo::^p)()=&Foo::bar;
i did find an article that showed how to convert a delegate to a
function pointer, but i sorta want to go the other way around.
thanks
class Foo { public: void bar() {} };
class Baz {
void qux() {
void (Foo::*p)()=&Foo::bar; // works fine
}
};
ref class RFoo { void bar() {} };
ref class RBaz {
void qux() {
void (Foo::^p)()=&Foo::bar; // C2589 C2143 C2059
}
};
but the compiler does not like: void (Foo::^p)()=&Foo::bar;
i did find an article that showed how to convert a delegate to a
function pointer, but i sorta want to go the other way around.
thanks
class Foo { public: void bar() {} };
class Baz {
void qux() {
void (Foo::*p)()=&Foo::bar; // works fine
}
};
ref class RFoo { void bar() {} };
ref class RBaz {
void qux() {
void (Foo::^p)()=&Foo::bar; // C2589 C2143 C2059
}
};