2010-06-09 00:52:24 +08:00
|
|
|
//===-- ModuleChild.cpp -----------------------------------------*- C++ -*-===//
|
|
|
|
//
|
|
|
|
// The LLVM Compiler Infrastructure
|
|
|
|
//
|
|
|
|
// This file is distributed under the University of Illinois Open Source
|
|
|
|
// License. See LICENSE.TXT for details.
|
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
|
|
|
#include "lldb/Core/ModuleChild.h"
|
|
|
|
|
|
|
|
using namespace lldb_private;
|
|
|
|
|
2012-02-24 09:59:29 +08:00
|
|
|
ModuleChild::ModuleChild (const lldb::ModuleSP &module_sp) :
|
|
|
|
m_module_wp (module_sp)
|
2010-06-09 00:52:24 +08:00
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
ModuleChild::ModuleChild (const ModuleChild& rhs) :
|
2012-02-24 09:59:29 +08:00
|
|
|
m_module_wp(rhs.m_module_wp)
|
2010-06-09 00:52:24 +08:00
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
ModuleChild::~ModuleChild()
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
const ModuleChild&
|
|
|
|
ModuleChild::operator= (const ModuleChild& rhs)
|
|
|
|
{
|
|
|
|
if (this != &rhs)
|
2012-02-24 09:59:29 +08:00
|
|
|
m_module_wp = rhs.m_module_wp;
|
2010-06-09 00:52:24 +08:00
|
|
|
return *this;
|
|
|
|
}
|
|
|
|
|
2012-02-24 09:59:29 +08:00
|
|
|
lldb::ModuleSP
|
2010-06-09 00:52:24 +08:00
|
|
|
ModuleChild::GetModule () const
|
|
|
|
{
|
2012-02-24 09:59:29 +08:00
|
|
|
return m_module_wp.lock();
|
2010-06-09 00:52:24 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
2012-02-24 09:59:29 +08:00
|
|
|
ModuleChild::SetModule (const lldb::ModuleSP &module_sp)
|
2010-06-09 00:52:24 +08:00
|
|
|
{
|
2012-02-24 09:59:29 +08:00
|
|
|
m_module_wp = module_sp;
|
2010-06-09 00:52:24 +08:00
|
|
|
}
|