diff options
Diffstat (limited to 'clang/lib/CodeGen/CGObjCGNU.cpp')
-rw-r--r-- | clang/lib/CodeGen/CGObjCGNU.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/clang/lib/CodeGen/CGObjCGNU.cpp b/clang/lib/CodeGen/CGObjCGNU.cpp index 4f65dddfdd9..d481e779267 100644 --- a/clang/lib/CodeGen/CGObjCGNU.cpp +++ b/clang/lib/CodeGen/CGObjCGNU.cpp @@ -1437,7 +1437,8 @@ void CGObjCGNU::GenerateClass(const ObjCImplementationDecl *OID) { } // Get the size of instances. - int instanceSize = Context.getASTObjCImplementationLayout(OID).getSize() / 8; + int instanceSize = + Context.getASTObjCImplementationLayout(OID).getSize().getQuantity(); // Collect information about instance variables. llvm::SmallVector<llvm::Constant*, 16> IvarNames; @@ -1447,7 +1448,7 @@ void CGObjCGNU::GenerateClass(const ObjCImplementationDecl *OID) { std::vector<llvm::Constant*> IvarOffsetValues; int superInstanceSize = !SuperClassDecl ? 0 : - Context.getASTObjCInterfaceLayout(SuperClassDecl).getSize() / 8; + Context.getASTObjCInterfaceLayout(SuperClassDecl).getSize().getQuantity(); // For non-fragile ivars, set the instance size to 0 - {the size of just this // class}. The runtime will then set this to the correct value on load. if (CGM.getContext().getLangOptions().ObjCNonFragileABI) { |