2010-06-09 00:52:24 +08:00
|
|
|
//===-- ModuleChild.cpp -----------------------------------------*- C++ -*-===//
|
|
|
|
//
|
2019-01-19 16:50:56 +08:00
|
|
|
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
|
|
|
|
// See https://llvm.org/LICENSE.txt for license information.
|
|
|
|
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
|
2010-06-09 00:52:24 +08:00
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
|
|
|
#include "lldb/Core/ModuleChild.h"
|
|
|
|
|
|
|
|
using namespace lldb_private;
|
|
|
|
|
2016-09-07 04:57:50 +08:00
|
|
|
ModuleChild::ModuleChild(const lldb::ModuleSP &module_sp)
|
|
|
|
: m_module_wp(module_sp) {}
|
2010-06-09 00:52:24 +08:00
|
|
|
|
2016-09-07 04:57:50 +08:00
|
|
|
ModuleChild::~ModuleChild() {}
|
2010-06-09 00:52:24 +08:00
|
|
|
|
2016-09-07 04:57:50 +08:00
|
|
|
const ModuleChild &ModuleChild::operator=(const ModuleChild &rhs) {
|
|
|
|
if (this != &rhs)
|
|
|
|
m_module_wp = rhs.m_module_wp;
|
|
|
|
return *this;
|
2010-06-09 00:52:24 +08:00
|
|
|
}
|
|
|
|
|
2016-09-07 04:57:50 +08:00
|
|
|
lldb::ModuleSP ModuleChild::GetModule() const { return m_module_wp.lock(); }
|
2010-06-09 00:52:24 +08:00
|
|
|
|
2016-09-07 04:57:50 +08:00
|
|
|
void ModuleChild::SetModule(const lldb::ModuleSP &module_sp) {
|
|
|
|
m_module_wp = module_sp;
|
2010-06-09 00:52:24 +08:00
|
|
|
}
|