POP QUIZ: What’s wrong with this code – part 2
Here is another snippet of code for you to look at and tell me what is wrong. As before, give your comment of what is wrong and I will post the answer and make the comments public tomorrow. This time it is C++ code and not specific to ASP.NET:
typedef bool (FUNC)(void *);
class Foo
{
virtual FUNC Method;
void *m_p;
};
bool Foo::Method(void *p)
{
return p == m_p;
};