Add virtual dtor to translation_unit.

* include/abg-ir.h (translation_unit): Add virtual dtor.
	* src/abg-ir.cc: Define.
This commit is contained in:
Benjamin Kosnik 2013-08-01 16:56:11 -07:00 committed by Dodji Seketeli
parent 1f702180e6
commit 8652e0f935
2 changed files with 7 additions and 1 deletions

View File

@ -172,7 +172,7 @@ struct traversable
/// This is the abstraction of the set of relevant artefacts (types,
/// variable declarations, functions, templates, etc) bundled together
/// into a translation unit.
class translation_unit : public virtual traversable
class translation_unit : public traversable
{
// Forbidden
translation_unit();
@ -201,6 +201,8 @@ public:
void
traverse(ir_node_visitor&);
virtual ~translation_unit();
private:
std::string m_path;
location_manager m_loc_mgr;

View File

@ -219,6 +219,10 @@ translation_unit::traverse(ir_node_visitor& v)
get_global_scope()->traverse(v);
}
translation_unit::~translation_unit()
{
}
// <Decl definition>
decl_base::decl_base(const std::string& name,