From 6a0746a92f0764f7af1968c84b141ccbe752919c Mon Sep 17 00:00:00 2001 From: Fangrui Song Date: Sun, 7 Apr 2019 03:58:42 +0000 Subject: Change some StringRef::data() reinterpret_cast to bytes_begin() or arrayRefFromStringRef() llvm-svn: 357852 --- llvm/lib/Object/WasmObjectFile.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'llvm/lib/Object/WasmObjectFile.cpp') diff --git a/llvm/lib/Object/WasmObjectFile.cpp b/llvm/lib/Object/WasmObjectFile.cpp index 9d521544593..16645002a6d 100644 --- a/llvm/lib/Object/WasmObjectFile.cpp +++ b/llvm/lib/Object/WasmObjectFile.cpp @@ -255,7 +255,7 @@ WasmObjectFile::WasmObjectFile(MemoryBufferRef Buffer, Error &Err) } ReadContext Ctx; - Ctx.Start = reinterpret_cast(getData().data()); + Ctx.Start = getData().bytes_begin(); Ctx.Ptr = Ctx.Start + 4; Ctx.End = Ctx.Start + getData().size(); -- cgit v1.2.3