Affected:
gcc (GCC) 3.3.2 20031001 (prerelease)
gcc (GCC) 3.4 20031001 (experimental)
probably more
The following code seems illegal as of my feeling for C++. However, it compiles without error.
-----------<gccbug.cc>------------
struct A { int ma; };
struct B { };
void foo()
{
B *b;
b->A::ma=0; // OOPS: A not a base of B
}