1 //===-- SBSymbol.h ----------------------------------------------*- C++ -*-===//
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
7 //===----------------------------------------------------------------------===//
9 #ifndef LLDB_SBSymbol_h_
10 #define LLDB_SBSymbol_h_
12 #include "lldb/API/SBAddress.h"
13 #include "lldb/API/SBDefines.h"
14 #include "lldb/API/SBInstructionList.h"
15 #include "lldb/API/SBTarget.h"
19 class LLDB_API SBSymbol {
25 SBSymbol(const lldb::SBSymbol &rhs);
27 const lldb::SBSymbol &operator=(const lldb::SBSymbol &rhs);
29 explicit operator bool() const;
33 const char *GetName() const;
35 const char *GetDisplayName() const;
37 const char *GetMangledName() const;
39 lldb::SBInstructionList GetInstructions(lldb::SBTarget target);
41 lldb::SBInstructionList GetInstructions(lldb::SBTarget target,
42 const char *flavor_string);
44 SBAddress GetStartAddress();
46 SBAddress GetEndAddress();
48 uint32_t GetPrologueByteSize();
52 bool operator==(const lldb::SBSymbol &rhs) const;
54 bool operator!=(const lldb::SBSymbol &rhs) const;
56 bool GetDescription(lldb::SBStream &description);
58 // Returns true if the symbol is externally visible in the module that it is
62 // Returns true if the symbol was synthetically generated from something
63 // other than the actual symbol table itself in the object file.
67 lldb_private::Symbol *get();
69 void reset(lldb_private::Symbol *);
72 friend class SBAddress;
74 friend class SBModule;
75 friend class SBSymbolContext;
77 SBSymbol(lldb_private::Symbol *lldb_object_ptr);
79 void SetSymbol(lldb_private::Symbol *lldb_object_ptr);
81 lldb_private::Symbol *m_opaque_ptr;
86 #endif // LLDB_SBSymbol_h_