summaryrefslogtreecommitdiff
path: root/lib/DebugInfo/PDB/Native/NativeSession.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/DebugInfo/PDB/Native/NativeSession.cpp')
-rw-r--r--lib/DebugInfo/PDB/Native/NativeSession.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/DebugInfo/PDB/Native/NativeSession.cpp b/lib/DebugInfo/PDB/Native/NativeSession.cpp
index 7e6843bceb7db..3ab381e76e628 100644
--- a/lib/DebugInfo/PDB/Native/NativeSession.cpp
+++ b/lib/DebugInfo/PDB/Native/NativeSession.cpp
@@ -70,12 +70,11 @@ uint64_t NativeSession::getLoadAddress() const { return 0; }
void NativeSession::setLoadAddress(uint64_t Address) {}
-std::unique_ptr<PDBSymbolExe> NativeSession::getGlobalScope() const {
- auto RawSymbol =
- llvm::make_unique<NativeExeSymbol>(const_cast<NativeSession &>(*this));
+std::unique_ptr<PDBSymbolExe> NativeSession::getGlobalScope() {
+ auto RawSymbol = llvm::make_unique<NativeExeSymbol>(*this, 0);
auto PdbSymbol(PDBSymbol::create(*this, std::move(RawSymbol)));
std::unique_ptr<PDBSymbolExe> ExeSymbol(
- static_cast<PDBSymbolExe *>(PdbSymbol.release()));
+ static_cast<PDBSymbolExe *>(PdbSymbol.release()));
return ExeSymbol;
}