1ac7ddfbfSEd Maste //===-- ModuleChild.cpp -----------------------------------------*- C++ -*-===// 2ac7ddfbfSEd Maste // 3ac7ddfbfSEd Maste // The LLVM Compiler Infrastructure 4ac7ddfbfSEd Maste // 5ac7ddfbfSEd Maste // This file is distributed under the University of Illinois Open Source 6ac7ddfbfSEd Maste // License. See LICENSE.TXT for details. 7ac7ddfbfSEd Maste // 8ac7ddfbfSEd Maste //===----------------------------------------------------------------------===// 9ac7ddfbfSEd Maste 10ac7ddfbfSEd Maste #include "lldb/Core/ModuleChild.h" 11ac7ddfbfSEd Maste 12ac7ddfbfSEd Maste using namespace lldb_private; 13ac7ddfbfSEd Maste ModuleChild(const lldb::ModuleSP & module_sp)14*435933ddSDimitry AndricModuleChild::ModuleChild(const lldb::ModuleSP &module_sp) 15*435933ddSDimitry Andric : m_module_wp(module_sp) {} 16ac7ddfbfSEd Maste ModuleChild(const ModuleChild & rhs)17*435933ddSDimitry AndricModuleChild::ModuleChild(const ModuleChild &rhs) 18*435933ddSDimitry Andric : m_module_wp(rhs.m_module_wp) {} 19ac7ddfbfSEd Maste ~ModuleChild()20*435933ddSDimitry AndricModuleChild::~ModuleChild() {} 21ac7ddfbfSEd Maste operator =(const ModuleChild & rhs)22*435933ddSDimitry Andricconst ModuleChild &ModuleChild::operator=(const ModuleChild &rhs) { 23ac7ddfbfSEd Maste if (this != &rhs) 24ac7ddfbfSEd Maste m_module_wp = rhs.m_module_wp; 25ac7ddfbfSEd Maste return *this; 26ac7ddfbfSEd Maste } 27ac7ddfbfSEd Maste GetModule() const28*435933ddSDimitry Andriclldb::ModuleSP ModuleChild::GetModule() const { return m_module_wp.lock(); } 29ac7ddfbfSEd Maste SetModule(const lldb::ModuleSP & module_sp)30*435933ddSDimitry Andricvoid ModuleChild::SetModule(const lldb::ModuleSP &module_sp) { 31ac7ddfbfSEd Maste m_module_wp = module_sp; 32ac7ddfbfSEd Maste } 33