diff options
author | Zachary Turner <zturner@google.com> | 2017-07-10 17:01:28 +0000 |
---|---|---|
committer | Zachary Turner <zturner@google.com> | 2017-07-10 17:01:28 +0000 |
commit | e584c228c647e6583e2d6627d9f2e489d9c647b3 (patch) | |
tree | f6ed6770508e3e4f434a7cc553a1580522f8a2bb | |
parent | 80e0f20bdec8e1775c1c5d350d9825bde47a2100 (diff) |
Build fixes for pdb-diff test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@307556 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | tools/llvm-pdbutil/Diff.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tools/llvm-pdbutil/Diff.cpp b/tools/llvm-pdbutil/Diff.cpp index 75e8f34bda0..98e0a860521 100644 --- a/tools/llvm-pdbutil/Diff.cpp +++ b/tools/llvm-pdbutil/Diff.cpp @@ -101,8 +101,8 @@ struct BinaryPathProvider { SmallString<64> removeRoot(StringRef Path, bool IsRight) const { SmallString<64> Native(Path); - SmallString<64> Root = - IsRight ? opts::diff::RightRoot : opts::diff::LeftRoot; + auto &RootOpt = IsRight ? opts::diff::RightRoot : opts::diff::LeftRoot; + SmallString<64> Root(static_cast<std::string>(RootOpt)); // pdb paths always use windows syntax, convert slashes to backslashes. sys::path::native(Root, sys::path::Style::windows); if (sys::path::has_stem(Root, sys::path::Style::windows)) @@ -449,7 +449,7 @@ diffOneModule(DiffPrinter &D, BinaryPathProvider PathProvider(28); auto Iter = llvm::find_if( - Other, [&Item, &PathProvider, ItemIsRight, + Other, [&PathProvider, ItemIsRight, L](const std::pair<uint32_t, DbiModuleDescriptor> &Other) { const auto *Left = L; const auto *Right = &Other; |