summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--llvm/lib/LTO/LTOModule.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/LTO/LTOModule.cpp b/llvm/lib/LTO/LTOModule.cpp
index 083af9e552e..d9bc9394d46 100644
--- a/llvm/lib/LTO/LTOModule.cpp
+++ b/llvm/lib/LTO/LTOModule.cpp
@@ -104,7 +104,7 @@ LTOModule *LTOModule::createFromOpenFileSlice(int fd, const char *path,
LTOModule *LTOModule::createFromBuffer(const void *mem, size_t length,
TargetOptions options,
std::string &errMsg, StringRef path) {
- StringRef Data((char *)mem, length);
+ StringRef Data((const char *)mem, length);
MemoryBufferRef Buffer(Data, path);
return makeLTOModule(Buffer, options, errMsg);
}
OpenPOWER on IntegriCloud