]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - contrib/llvm-project/lldb/source/Plugins/SymbolFile/DWARF/DWARFCompileUnit.h
Merge llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp
[FreeBSD/FreeBSD.git] / contrib / llvm-project / lldb / source / Plugins / SymbolFile / DWARF / DWARFCompileUnit.h
1 //===-- DWARFCompileUnit.h --------------------------------------*- C++ -*-===//
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 #ifndef LLDB_SOURCE_PLUGINS_SYMBOLFILE_DWARF_DWARFCOMPILEUNIT_H
10 #define LLDB_SOURCE_PLUGINS_SYMBOLFILE_DWARF_DWARFCOMPILEUNIT_H
11
12 #include "DWARFUnit.h"
13 #include "llvm/Support/Error.h"
14
15 class DWARFCompileUnit : public DWARFUnit {
16 public:
17   void BuildAddressRangeTable(DWARFDebugAranges *debug_aranges) override;
18
19   void Dump(lldb_private::Stream *s) const override;
20
21   static bool classof(const DWARFUnit *unit) { return !unit->IsTypeUnit(); }
22
23 private:
24   DWARFCompileUnit(SymbolFileDWARF &dwarf, lldb::user_id_t uid,
25                    const DWARFUnitHeader &header,
26                    const DWARFAbbreviationDeclarationSet &abbrevs,
27                    DIERef::Section section, bool is_dwo)
28       : DWARFUnit(dwarf, uid, header, abbrevs, section, is_dwo) {}
29
30   DWARFCompileUnit(const DWARFCompileUnit &) = delete;
31   const DWARFCompileUnit &operator=(const DWARFCompileUnit &) = delete;
32
33   friend class DWARFUnit;
34 };
35
36 #endif // LLDB_SOURCE_PLUGINS_SYMBOLFILE_DWARF_DWARFCOMPILEUNIT_H