1//===-- ModuleChild.cpp ---------------------------------------------------===// 2// 3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 4// See https://llvm.org/LICENSE.txt for license information. 5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 6// 7//===----------------------------------------------------------------------===// 8 9#include "lldb/Core/ModuleChild.h" 10 11using namespace lldb_private; 12 13ModuleChild::ModuleChild(const lldb::ModuleSP &module_sp) 14 : m_module_wp(module_sp) {} 15 16ModuleChild::~ModuleChild() {} 17 18const ModuleChild &ModuleChild::operator=(const ModuleChild &rhs) { 19 if (this != &rhs) 20 m_module_wp = rhs.m_module_wp; 21 return *this; 22} 23 24lldb::ModuleSP ModuleChild::GetModule() const { return m_module_wp.lock(); } 25 26void ModuleChild::SetModule(const lldb::ModuleSP &module_sp) { 27 m_module_wp = module_sp; 28} 29