Simplify pointer creation with the new Type::getInt*Ptr methods.
llvm-svn: 83964
This commit is contained in:
@@ -411,8 +411,7 @@ void CodeGenModule::EmitLLVMUsed() {
|
||||
if (LLVMUsed.empty())
|
||||
return;
|
||||
|
||||
llvm::Type *i8PTy =
|
||||
llvm::PointerType::getUnqual(llvm::Type::getInt8Ty(VMContext));
|
||||
const llvm::Type *i8PTy = llvm::Type::getInt8PtrTy(VMContext);
|
||||
|
||||
// Convert LLVMUsed to what ConstantArray needs.
|
||||
std::vector<llvm::Constant*> UsedArray;
|
||||
@@ -477,8 +476,7 @@ llvm::Constant *CodeGenModule::EmitAnnotateAttr(llvm::GlobalValue *GV,
|
||||
|
||||
// get [N x i8] constants for the annotation string, and the filename string
|
||||
// which are the 2nd and 3rd elements of the global annotation structure.
|
||||
const llvm::Type *SBP =
|
||||
llvm::PointerType::getUnqual(llvm::Type::getInt8Ty(VMContext));
|
||||
const llvm::Type *SBP = llvm::Type::getInt8PtrTy(VMContext);
|
||||
llvm::Constant *anno = llvm::ConstantArray::get(VMContext,
|
||||
AA->getAnnotation(), true);
|
||||
llvm::Constant *unit = llvm::ConstantArray::get(VMContext,
|
||||
|
||||
Reference in New Issue
Block a user