diff options
author | John McCall <rjmccall@apple.com> | 2010-08-05 22:02:13 +0000 |
---|---|---|
committer | John McCall <rjmccall@apple.com> | 2010-08-05 22:02:13 +0000 |
commit | 491462425a8aaf3f1b3d4d9879e58e9368dc2bdc (patch) | |
tree | b2ac69347c2ebbbe7bbe16f412c96a7f23e66e46 /clang/test/CodeGenCXX/mangle.cpp | |
parent | 638c82321184b5bd644e3b5248354e9c4d59d786 (diff) | |
download | bcm5719-llvm-491462425a8aaf3f1b3d4d9879e58e9368dc2bdc.tar.gz bcm5719-llvm-491462425a8aaf3f1b3d4d9879e58e9368dc2bdc.zip |
Don't crash when mangling empty anonymous unions. We never actually *need*
these, but it's convenient to mangle them when deferring them (in the 99.99%
case where it's not an anonymous union, of course).
llvm-svn: 110381
Diffstat (limited to 'clang/test/CodeGenCXX/mangle.cpp')
-rw-r--r-- | clang/test/CodeGenCXX/mangle.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/clang/test/CodeGenCXX/mangle.cpp b/clang/test/CodeGenCXX/mangle.cpp index 3a2e112f16c..4152dabc0b4 100644 --- a/clang/test/CodeGenCXX/mangle.cpp +++ b/clang/test/CodeGenCXX/mangle.cpp @@ -529,3 +529,14 @@ namespace test15 { // CHECK: define weak_odr void @_ZN6test151fILi7EEEvNS_1SIXplT_LNS_1EE3EEEE( template void f<7>(S<7 + e>); } + +// rdar://problem/8125400. Don't crash. +namespace test16 { + static union {}; + static union { union {}; }; + static union { struct {}; }; + static union { union { union {}; }; }; + static union { union { struct {}; }; }; + static union { struct { union {}; }; }; + static union { struct { struct {}; }; }; +} |