diff options
author | Erich Keane <erich.keane@intel.com> | 2022-03-31 07:27:11 -0700 |
---|---|---|
committer | Erich Keane <erich.keane@intel.com> | 2022-04-01 11:31:14 -0700 |
commit | 4cf98f973a13c5049322abff43f0dff3c214311b (patch) | |
tree | c8bebd698e112ba64858ccf94f6ba256b7917bc0 /clang/lib/CodeGen/CodeGenModule.h | |
parent | b36be2f77f7e7cc5af671af3ab99be07f6955718 (diff) | |
download | llvm-4cf98f973a13c5049322abff43f0dff3c214311b.zip llvm-4cf98f973a13c5049322abff43f0dff3c214311b.tar.gz llvm-4cf98f973a13c5049322abff43f0dff3c214311b.tar.bz2 |
[GH54588]Fix ItaniumMangler for NTTP unnamed unions w/ unnamed structs
As reported in https://github.com/llvm/llvm-project/issues/54588
and discussed in https://github.com/itanium-cxx-abi/cxx-abi/issues/139
We are supposed to do a DFS, pre-order, decl-order search for a name for
the union in this case. Prevoiusly we crashed because the IdentiferInfo
pointer was nullptr, so this makes sure we have a name in the cases
described by the ABI.
I added an llvm-unreachable to cover an unexpected case at the end of
the new function with information/reference to the ABI in case we come
up with some way to get back to here.
Differential Revision: https://reviews.llvm.org/D122820
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.h')
0 files changed, 0 insertions, 0 deletions