commit | a048c302154af9091107d6e84c12146588255f24 | [log] [tgz] |
---|---|---|
author | John McCall <rjmccall@apple.com> | Tue Nov 30 10:12:16 2010 +0000 |
committer | John McCall <rjmccall@apple.com> | Tue Nov 30 10:12:16 2010 +0000 |
tree | 09e39948a5afee2f4979ff0df4f05e4fdaf2fd54 | |
parent | 5e9fde5d26ecc83760dfa3a91f55cf7ebdc20aaf [diff] [blame] |
Make the dumper safe against null declaration names. llvm-svn: 120421
diff --git a/clang/lib/AST/DumpXML.cpp b/clang/lib/AST/DumpXML.cpp index ea9f1cc..5f1a396 100644 --- a/clang/lib/AST/DumpXML.cpp +++ b/clang/lib/AST/DumpXML.cpp
@@ -255,6 +255,9 @@ } void setName(DeclarationName Name) { + if (!Name) + return set("name", ""); + // Common case. if (Name.isIdentifier()) return set("name", Name.getAsIdentifierInfo()->getName());