DebugInfo: Don't use enumerators in template names for debug info as they are not...
authorDavid Blaikie <dblaikie@gmail.com>
Tue, 5 Apr 2022 17:16:42 +0000 (17:16 +0000)
committerDavid Blaikie <dblaikie@gmail.com>
Tue, 5 Apr 2022 17:16:42 +0000 (17:16 +0000)
commitbb3980ae9fa7e19540080285f2bf2d960ea802fc
tree3fb73b81f1fd5f139eb3d932c32b6682a7cb982f
parent6efda5e6d6531ced6e35ccb3f6499ca13b8edb60
DebugInfo: Don't use enumerators in template names for debug info as they are not canonical

Since enumerators may not be available in every translation unit they
can't be reliably used to name entities. (this also makes simplified
template name roundtripping infeasible - since the expected name could
only be rebuilt if the enumeration definition could be found (or only if
it couldn't be found, depending on the context of the original name))
clang/include/clang/AST/PrettyPrinter.h
clang/lib/AST/TemplateBase.cpp
clang/lib/CodeGen/CGDebugInfo.cpp
clang/test/CodeGenCXX/debug-info-simple-template-names.cpp
llvm/lib/DebugInfo/DWARF/DWARFDie.cpp
llvm/test/tools/llvm-dwarfdump/X86/prettyprint_types.s
llvm/test/tools/llvm-dwarfdump/X86/simplified-template-names.s