LIEF: Library to Instrument Executable Formats
Version 1.0.0
Toggle main menu visibility
Loading...
Searching...
No Matches
lief-install
x86_64
static
include
LIEF
DWARF
Scope.hpp
Go to the documentation of this file.
1
/* Copyright 2022 - 2026 R. Thomas
2
*
3
* Licensed under the Apache License, Version 2.0 (the "License");
4
* you may not use this file except in compliance with the License.
5
* You may obtain a copy of the License at
6
*
7
* http://www.apache.org/licenses/LICENSE-2.0
8
*
9
* Unless required by applicable law or agreed to in writing, software
10
* distributed under the License is distributed on an "AS IS" BASIS,
11
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
* See the License for the specific language governing permissions and
13
* limitations under the License.
14
*/
15
#ifndef LIEF_DWARF_SCOPE_H
16
#define LIEF_DWARF_SCOPE_H
17
18
#include <cstdint>
19
#include <memory>
20
#include <string>
21
22
#include "
LIEF/visibility.h
"
23
24
namespace
LIEF
{
25
namespace
dwarf
{
26
27
namespace
details
{
28
class
Scope;
29
}
30
33
class
LIEF_API
Scope
{
34
public
:
35
enum class
TYPE
: uint32_t {
36
UNKNOWN = 0,
37
UNION,
38
CLASS,
39
STRUCT,
40
NAMESPACE,
41
FUNCTION,
42
COMPILATION_UNIT,
43
};
44
Scope
(std::unique_ptr<details::Scope> impl);
45
47
std::string
name
()
const
;
48
50
std::unique_ptr<Scope>
parent
()
const
;
51
53
TYPE
type
()
const
;
54
57
std::string
chained
(
const
std::string& sep =
"::"
)
const
;
58
59
~Scope
();
60
private
:
61
std::unique_ptr<details::Scope> impl_;
62
};
63
64
}
65
}
66
#endif
LIEF::dwarf::Scope::~Scope
~Scope()
LIEF::dwarf::Scope::type
TYPE type() const
The current scope type.
LIEF::dwarf::Scope::parent
std::unique_ptr< Scope > parent() const
Parent scope (if any).
LIEF::dwarf::Scope::name
std::string name() const
Name of the scope. For instance namespace's name or function's name.
LIEF::dwarf::Scope::chained
std::string chained(const std::string &sep="::") const
Represent the whole chain of all (parent) scopes using the provided separator. E.g....
LIEF::dwarf::Scope::TYPE
TYPE
Definition
Scope.hpp:35
LIEF::dwarf::Scope::Scope
Scope(std::unique_ptr< details::Scope > impl)
LIEF::dwarf::details
Definition
DWARF/CompilationUnit.hpp:30
LIEF::dwarf
Namespace for the DWARF debug format.
Definition
DWARF/CompilationUnit.hpp:28
LIEF
LIEF namespace.
Definition
Abstract/Binary.hpp:40
visibility.h
LIEF_API
#define LIEF_API
Definition
visibility.h:41
Generated by
1.17.0