Hacking happily along at the POV-Ray code, I stumbled across this MS
Visual Studio 2005 C++ anomaly:
class A
{
protected:
void a() {}
};
class B : public A
{
protected:
void b(A* other)
{
this->a(); // (1)
other->a(); // (2)
}
};
While (1) compiles fine, (2) raises an error C2248, "'A::a' : cannot
access protected member declared in class 'A'"
What the F*** am I doing wrong here?
Post a reply to this message
|