headers/bsd: Add sys/queue.h.
[haiku.git] / src / kits / debugger / dwarf / TypeUnit.cpp
blob6dd4113bd676c20e0522867ef0d8cd6b388c7a2e
1 /*
2 * Copyright 2013, Rene Gollent, rene@gollent.com.
3 * Distributed under the terms of the MIT License.
4 */
5 #include "TypeUnit.h"
7 #include <new>
9 #include "DebugInfoEntries.h"
12 TypeUnit::TypeUnit(off_t headerOffset, off_t contentOffset,
13 off_t totalSize, off_t abbreviationOffset, off_t typeOffset,
14 uint8 addressSize, uint64 signature, bool isDwarf64)
16 BaseUnit(headerOffset, contentOffset, totalSize, abbreviationOffset,
17 addressSize, isDwarf64),
18 fUnitEntry(NULL),
19 fTypeEntry(NULL),
20 fSignature(signature),
21 fTypeOffset(typeOffset)
26 TypeUnit::~TypeUnit()
31 void
32 TypeUnit::SetUnitEntry(DIETypeUnit* entry)
34 fUnitEntry = entry;
38 DebugInfoEntry*
39 TypeUnit::TypeEntry() const
41 return fTypeEntry;
45 void
46 TypeUnit::SetTypeEntry(DebugInfoEntry* entry)
48 fTypeEntry = entry;
52 dwarf_unit_kind
53 TypeUnit::Kind() const
55 return dwarf_unit_kind_type;