Compiler Error 728

you are accessing a namespace as if its a member; i.e.

class B {  int value() { return 1; } };
namespace thing {
  B b;
}

class foo {
   B m_thing;
   int getThingBad() { return thing.value(); } // fails
   int getThingGood() { return m_thing.value(); } // works
}
class fine {
   B thing;
   int getThingGood() { return thing.value(); } // works
}

in the above example, the error is a typo in foo::getThingBad (i.e. missing m_)


All wikipages