While we are at C++ namespaces now - here is another problem I noticed when using the boost::tuples lib.
From it's docu:
"All definitions are in namespace ::boost::tuples, but the most common names are lifted to namespace ::boost with using declarations."
So e.g. ::boost::tuples::make_tuple(...) is aliased as ::boost::make_tuple(...). But when using these full-qualified forms, only the former is recognized by VAX, not the latter aliased form.
It turns out, that VAX doesn't seem to recognize identifiers which are using-declared in a namespace when you access them with the full qualified form. On the other hand, if you do without full qualification by putting in a using directive for that namespace, VAX works correctly.
(Please note: not a using directive for the original namespace of the identifier, but for the other namespace containing the using declaration. Of course both will work, but the interesting fact is, that VAX doesn't have a problem with the inner using declaration itself but with the qualification of the containing namespace.)
Example:
namespace test1
{
void testfunc1(){}
}
namespace test2
{
using ::test1::testfunc1;
}
void testfunc3()
{
::test1::testfunc1(); // correctly recognized by VAX
::test2::testfunc1(); // not recognized by VAX
}
void testfunc4()
{
using namespace test2;
testfunc1(); // now correctly recognized by VAX
}