From 0953e767ff7817f97b3ab20896b229891eeff45b Mon Sep 17 00:00:00 2001 From: John McCall Date: Thu, 24 Sep 2009 19:53:00 +0000 Subject: Refactor the representation of qualifiers to bring ExtQualType out of the Type hierarchy. Demote 'volatile' to extended-qualifier status. Audit our use of qualifiers and fix a few places that weren't dealing with qualifiers quite right; many more remain. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@82705 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/CodeGen/CodeGenTypes.cpp | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'lib/CodeGen/CodeGenTypes.cpp') diff --git a/lib/CodeGen/CodeGenTypes.cpp b/lib/CodeGen/CodeGenTypes.cpp index 6826122ad9..87b3d1144f 100644 --- a/lib/CodeGen/CodeGenTypes.cpp +++ b/lib/CodeGen/CodeGenTypes.cpp @@ -267,7 +267,7 @@ const llvm::Type *CodeGenTypes::ConvertNewType(QualType T) { case Type::VariableArray: { const VariableArrayType &A = cast(Ty); - assert(A.getIndexTypeQualifier() == 0 && + assert(A.getIndexTypeCVRQualifiers() == 0 && "FIXME: We only handle trivial array types so far!"); // VLAs resolve to the innermost element type; this matches // the return of alloca, and there isn't any obviously better choice. @@ -275,7 +275,7 @@ const llvm::Type *CodeGenTypes::ConvertNewType(QualType T) { } case Type::IncompleteArray: { const IncompleteArrayType &A = cast(Ty); - assert(A.getIndexTypeQualifier() == 0 && + assert(A.getIndexTypeCVRQualifiers() == 0 && "FIXME: We only handle trivial array types so far!"); // int X[] -> [0 x int] return llvm::ArrayType::get(ConvertTypeForMemRecursive(A.getElementType()), 0); @@ -312,10 +312,6 @@ const llvm::Type *CodeGenTypes::ConvertNewType(QualType T) { return GetFunctionType(getFunctionInfo(FNPT), true); } - case Type::ExtQual: - return - ConvertTypeRecursive(QualType(cast(Ty).getBaseType(), 0)); - case Type::ObjCInterface: { // Objective-C interfaces are always opaque (outside of the // runtime, which can do whatever it likes); we never refine -- cgit v1.2.3-18-g5258