mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-02-21 21:11:36 +00:00
Don't forget to print address space qualifiers when printing out the type table! Thanks to Gordon Henriksen for pointing this out.
llvm-svn: 45147
This commit is contained in:
parent
d0377b8eb2
commit
efdf2791b2
@ -808,7 +808,10 @@ std::ostream &AssemblyWriter::printTypeAtLeastOneLevel(const Type *Ty) {
|
||||
if (STy->isPacked())
|
||||
Out << '>';
|
||||
} else if (const PointerType *PTy = dyn_cast<PointerType>(Ty)) {
|
||||
printType(PTy->getElementType()) << '*';
|
||||
printType(PTy->getElementType());
|
||||
if (unsigned AddressSpace = PTy->getAddressSpace())
|
||||
Out << " addrspace(" << AddressSpace << ")";
|
||||
Out << '*';
|
||||
} else if (const ArrayType *ATy = dyn_cast<ArrayType>(Ty)) {
|
||||
Out << '[' << ATy->getNumElements() << " x ";
|
||||
printType(ATy->getElementType()) << ']';
|
||||
|
@ -114,7 +114,7 @@ let test_types () =
|
||||
end;
|
||||
|
||||
begin group "qualified_pointer";
|
||||
(* XXX: grep {QualPtrTy.*i8.*3.*\*} < %t.ll
|
||||
(* RUN: grep {QualPtrTy.*i8.*3.*\*} < %t.ll
|
||||
*)
|
||||
let ty = qualified_pointer_type i8_type 3 in
|
||||
insist (define_type_name "QualPtrTy" ty m);
|
||||
|
Loading…
x
Reference in New Issue
Block a user