Consider the following code.
namespace A::B::C::D::E {
struct X { };
}
namespace B {
using namespace A::B::C::D::E;
// or, using A::B::C::D::E::X;
// or, using X = A::B::C::D::E::X;
}
Let's say I use B::X incorrectly in some way and get an error. That error, in clang at least, will look something like
error: ... for type A::B::C::D::E::X
.
I'd much rather have the error stated for B::X
.
Is there a way to configure clang error messages to use the locations of using declarations, instead of the aliased entity?