The formal way to address variable in inherited class is:
Base::myVar = 0;// orthis->myVar;
GCC requires this for templated classes, MVC never requires it (which is incorrect).
Obviously, when you are passed an instance, you can only access its public members, or members you declared. In this case, the members declared by Derived - but not base.
I have no clue why this is required, but there's probably an arcane special case with multiple inheritance or some scope resolution or whatnot.
A Foo can only access public members of any other type, and all members declared by Foo, regardless of inheritance.
Either way, I personally never encountered this problem before, or had the need for such access. Are you sure you need this?