aboutsummaryrefslogtreecommitdiff
path: root/lib/VMCore/Instructions.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/VMCore/Instructions.cpp')
-rw-r--r--lib/VMCore/Instructions.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/VMCore/Instructions.cpp b/lib/VMCore/Instructions.cpp
index c2fddfa347..f3d15cb2b8 100644
--- a/lib/VMCore/Instructions.cpp
+++ b/lib/VMCore/Instructions.cpp
@@ -498,7 +498,7 @@ static Value *createMalloc(Instruction *InsertBefore, BasicBlock *InsertAtEnd,
// Create the call to Malloc.
BasicBlock* BB = InsertBefore ? InsertBefore->getParent() : InsertAtEnd;
Module* M = BB->getParent()->getParent();
- const Type *BPTy = PointerType::getUnqual(Type::getInt8Ty(BB->getContext()));
+ const Type *BPTy = Type::getInt8PtrTy(BB->getContext());
// prototype malloc as "void *malloc(size_t)"
Constant *MallocF = M->getOrInsertFunction("malloc", BPTy, IntPtrTy, NULL);
if (!cast<Function>(MallocF)->doesNotAlias(0))