This fixes calls to the dump() routine for cases when the NamedDecl's getQualifier() is NULL.
Since ASTDumper is a debugging utility, it should handle the case that getQualifier() is NULL. I don't know if the crash can happen in clang, but it can happen while debugging lldb for the source:
namespace ns { int func(); int context() { // execution context is here } }
commands in lldb being debugged:
p ns::func() <- adds the namespace to decl map in lldb p func() <- crash while dumping the NamedDecl of the function's parent's declaration contexts because getQualifier() is NULL.