Silencing a -Wcast-qual warning. NFC.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@216068 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Aaron Ballman 2014-08-20 12:54:13 +00:00
parent 0e9c68e6bc
commit a2bec69360

View File

@ -104,7 +104,7 @@ LTOModule *LTOModule::createFromOpenFileSlice(int fd, const char *path,
LTOModule *LTOModule::createFromBuffer(const void *mem, size_t length, LTOModule *LTOModule::createFromBuffer(const void *mem, size_t length,
TargetOptions options, TargetOptions options,
std::string &errMsg, StringRef path) { std::string &errMsg, StringRef path) {
StringRef Data((char *)mem, length); StringRef Data((const char *)mem, length);
MemoryBufferRef Buffer(Data, path); MemoryBufferRef Buffer(Data, path);
return makeLTOModule(Buffer, options, errMsg); return makeLTOModule(Buffer, options, errMsg);
} }