diff options
author | Chris Lattner <sabre@nondot.org> | 2010-08-28 04:09:24 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2010-08-28 04:09:24 +0000 |
commit | 13ee795c428d73b6d15a126143800762f34db3f0 (patch) | |
tree | 7241aeb832cf0a604afcf108034b27bb6d86203b /llvm/lib/VMCore/AsmWriter.cpp | |
parent | 504e5100d30106850f1e059e27af4cae03425ac4 (diff) | |
download | bcm5719-llvm-13ee795c428d73b6d15a126143800762f34db3f0.tar.gz bcm5719-llvm-13ee795c428d73b6d15a126143800762f34db3f0.zip |
remove unions from LLVM IR. They are severely buggy and not
being actively maintained, improved, or extended.
llvm-svn: 112356
Diffstat (limited to 'llvm/lib/VMCore/AsmWriter.cpp')
-rw-r--r-- | llvm/lib/VMCore/AsmWriter.cpp | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/llvm/lib/VMCore/AsmWriter.cpp b/llvm/lib/VMCore/AsmWriter.cpp index c7f27c62639..ab9dd3e7f96 100644 --- a/llvm/lib/VMCore/AsmWriter.cpp +++ b/llvm/lib/VMCore/AsmWriter.cpp @@ -238,21 +238,6 @@ void TypePrinting::CalcTypeName(const Type *Ty, OS << '>'; break; } - case Type::UnionTyID: { - const UnionType *UTy = cast<UnionType>(Ty); - OS << "union {"; - for (StructType::element_iterator I = UTy->element_begin(), - E = UTy->element_end(); I != E; ++I) { - OS << ' '; - CalcTypeName(*I, TypeStack, OS); - if (llvm::next(I) == UTy->element_end()) - OS << ' '; - else - OS << ','; - } - OS << '}'; - break; - } case Type::PointerTyID: { const PointerType *PTy = cast<PointerType>(Ty); CalcTypeName(PTy->getElementType(), TypeStack, OS); @@ -1042,16 +1027,6 @@ static void WriteConstantInternal(raw_ostream &Out, const Constant *CV, return; } - if (const ConstantUnion *CU = dyn_cast<ConstantUnion>(CV)) { - Out << "{ "; - TypePrinter.print(CU->getOperand(0)->getType(), Out); - Out << ' '; - WriteAsOperandInternal(Out, CU->getOperand(0), &TypePrinter, Machine, - Context); - Out << " }"; - return; - } - if (const ConstantVector *CP = dyn_cast<ConstantVector>(CV)) { const Type *ETy = CP->getType()->getElementType(); assert(CP->getNumOperands() > 0 && |