Hi!
I have two classes: test1 and test2. A function in test1 takes a function as parameter:
typedef void (funcptr)(int, int);
class test1
{
public:
void Init(funcptr *func);
};
//test2:
class test2
{
public:
void func(int a, int b);
void Init();
};
void test2::Init()
{
test1 qqq;
qqq.Init(func);
}
And it doesn't compile... why ???
If I declare the func as a global function:
void func(int a, int b)
{
}
and:
void test2::Init()
{
test1 qqq;
qqq.Init(::func);
}
it compiles !!
Please, help...
thx,
ferceg
Edited by - ferceg on November 15, 2001 10:08:48 AM