diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2020-07-26 19:36:28 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2020-07-26 19:36:28 +0000 |
commit | cfca06d7963fa0909f90483b42a6d7d194d01e08 (patch) | |
tree | 209fb2a2d68f8f277793fc8df46c753d31bc853b /llvm/tools/llvm-pdbutil/StreamUtil.cpp | |
parent | 706b4fc47bbc608932d3b491ae19a3b9cde9497b (diff) |
Notes
Diffstat (limited to 'llvm/tools/llvm-pdbutil/StreamUtil.cpp')
-rw-r--r-- | llvm/tools/llvm-pdbutil/StreamUtil.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/tools/llvm-pdbutil/StreamUtil.cpp b/llvm/tools/llvm-pdbutil/StreamUtil.cpp index 7dfc2beefe78..d0d0a9fbe927 100644 --- a/llvm/tools/llvm-pdbutil/StreamUtil.cpp +++ b/llvm/tools/llvm-pdbutil/StreamUtil.cpp @@ -32,7 +32,7 @@ std::string StreamInfo::getLongName() const { StreamInfo StreamInfo::createStream(StreamPurpose Purpose, StringRef Name, uint32_t StreamIndex) { StreamInfo Result; - Result.Name = Name; + Result.Name = std::string(Name); Result.StreamIndex = StreamIndex; Result.Purpose = Purpose; return Result; @@ -41,7 +41,7 @@ StreamInfo StreamInfo::createStream(StreamPurpose Purpose, StringRef Name, StreamInfo StreamInfo::createModuleStream(StringRef Module, uint32_t StreamIndex, uint32_t Modi) { StreamInfo Result; - Result.Name = Module; + Result.Name = std::string(Module); Result.StreamIndex = StreamIndex; Result.ModuleIndex = Modi; Result.Purpose = StreamPurpose::ModuleStream; @@ -90,7 +90,7 @@ void llvm::pdb::discoverStreamPurposes(PDBFile &File, if (Info) { for (auto &NSE : Info->named_streams()) { if (NSE.second != kInvalidStreamIndex) - NamedStreams[NSE.second] = NSE.first(); + NamedStreams[NSE.second] = std::string(NSE.first()); } } |