217 template<
typename Arg1,
typename... Args>
650 std::set<
size_t> visited_;
655template<typename Arg1, typename... Args>
656void Visitor::operator()(Arg1&& arg1, Args&&... args) {
663 auto hash =
reinterpret_cast<size_t>(&obj);
664 if (visited_.find(
hash) != std::end(visited_)) {
669 visited_.insert(
hash);
Abstract binary that exposes an uniform API for the different executable file formats.
Definition Abstract/Binary.hpp:53
Class that represents a function in the binary.
Definition Abstract/Function.hpp:29
Class which represents a MachO binary.
Definition MachO/Binary.hpp:88
Class that provides an interface over a binding operation.
Definition BindingInfo.hpp:39
Definition BuildVersion.hpp:34
This class represents a symbol binding operation associated with the LC_DYLD_CHAINED_FIXUPS command.
Definition ChainedBindingInfo.hpp:48
Definition CodeSignatureDir.hpp:36
Definition CodeSignature.hpp:37
Interface over an entry in the DataInCode command.
Definition DataCodeEntry.hpp:33
Interface of the LC_DATA_IN_CODE command This command is used to list slices of code sections that co...
Definition DataInCode.hpp:42
This class represents a symbol binding operation associated with the LC_DYLD_INFO bytecode.
Definition DyldBindingInfo.hpp:34
Class that represents a LC_DYLD_ENVIRONMENT command which is used by the Mach-O linker/loader to init...
Definition DyldEnvironment.hpp:34
Class that represents the LC_DYLD_EXPORTS_TRIE command.
Definition DyldExportsTrie.hpp:40
Class which represents a library dependency.
Definition DylibCommand.hpp:34
Class that represents the Mach-O linker, also named loader. Most of the time, DylinkerCommand::name()...
Definition DylinkerCommand.hpp:34
Class that represents the LC_DYSYMTAB command.
Definition DynamicSymbolCommand.hpp:40
Class that represents the LC_ENCRYPTION_INFO / LC_ENCRYPTION_INFO_64 commands.
Definition EncryptionInfo.hpp:35
Class that provides an interface over the Dyld export info.
Definition ExportInfo.hpp:38
Class associated with the LC_FILESET_ENTRY commands.
Definition FilesetCommand.hpp:35
Class which represents the LC_FUNCTION_STARTS command.
Definition FunctionStarts.hpp:39
Class which represents the LC_LINKER_OPTIMIZATION_HINT command.
Definition LinkerOptHint.hpp:37
Based class for the Mach-O load commands.
Definition LoadCommand.hpp:37
Class that represent the LC_MAIN command. This kind of command can be used to determine the entrypoin...
Definition MainCommand.hpp:33
Class that represent the LC_NOTE command.
Definition NoteCommand.hpp:35
Class that represents the LC_RPATH command.
Definition RPathCommand.hpp:36
Class that represents a relocation found in the DyldInfo structure.
Definition RelocationDyld.hpp:33
Class that represents a rebase relocation found in the LC_DYLD_CHAINED_FIXUPS command.
Definition RelocationFixup.hpp:52
Class that represents a relocation presents in the MachO object file (.o). Usually,...
Definition RelocationObject.hpp:38
Class that represents a Mach-O relocation.
Definition MachO/Relocation.hpp:40
Class that represents the LC_ROUTINE/LC_ROUTINE64 commands. Accodring to the Mach-O loader....
Definition Routine.hpp:38
Class that represents a Mach-O section.
Definition MachO/Section.hpp:46
Class which represents a LoadCommand::TYPE::SEGMENT / LoadCommand::TYPE::SEGMENT_64 command.
Definition SegmentCommand.hpp:50
Class that represents the LoadCommand::TYPE::SEGMENT_SPLIT_INFO command.
Definition SegmentSplitInfo.hpp:35
Class that represents the MachO LoadCommand::TYPE::SOURCE_VERSION This command is used to provide the...
Definition SourceVersion.hpp:35
Class that represents the SubFramework command. Accodring to the Mach-O loader.h documentation:
Definition SubFramework.hpp:46
Class that represents the LC_SYMTAB command.
Definition SymbolCommand.hpp:35
Class that represents a Symbol in a Mach-O file.
Definition MachO/Symbol.hpp:47
Class that represents the LC_THREAD / LC_UNIXTHREAD commands and that can be used to get the binary e...
Definition ThreadCommand.hpp:41
Class which represents the LC_TWOLEVEL_HINTS command.
Definition TwoLevelHints.hpp:39
Class that represents the UUID command.
Definition UUIDCommand.hpp:35
Generic class when the command is not recognized by LIEF.
Definition UnknownCommand.hpp:32
Class that wraps the LC_VERSION_MIN_MACOSX, LC_VERSION_MIN_IPHONEOS, ... commands.
Definition VersionMin.hpp:33
Class which represents an abstracted Relocation.
Definition Abstract/Relocation.hpp:27
Class which represents an abstracted section.
Definition Abstract/Section.hpp:29
This class represents a symbol in an executable format.
Definition Abstract/Symbol.hpp:28
virtual void operator()()
virtual void visit(const Object &)
void dispatch(const T &obj)
Definition Visitor.hpp:662
LIEF namespace.
Definition Abstract/Binary.hpp:40
Hash::value_type hash(const Object &v)
#define LIEF_API
Definition visibility.h:41
#define LIEF_ABSTRACT_FORWARD(OBJ)
Definition visitor_macros.hpp:126
#define LIEF_VDEX_FORWARD(OBJ)
Definition visitor_macros.hpp:98
#define LIEF_MACHO_VISITABLE(OBJ)
Definition visitor_macros.hpp:57
#define LIEF_ART_FORWARD(OBJ)
Definition visitor_macros.hpp:113
#define LIEF_ABSTRACT_VISITABLE(OBJ)
Definition visitor_macros.hpp:129
#define LIEF_DEX_VISITABLE(OBJ)
Definition visitor_macros.hpp:87
#define LIEF_OAT_FORWARD(OBJ)
Definition visitor_macros.hpp:68
#define LIEF_PE_VISITABLE(OBJ)
Definition visitor_macros.hpp:28
#define LIEF_VDEX_VISITABLE(OBJ)
Definition visitor_macros.hpp:102
#define LIEF_DEX_FORWARD(OBJ)
Definition visitor_macros.hpp:83
#define LIEF_MACHO_FORWARD(OBJ)
Definition visitor_macros.hpp:53
#define LIEF_ART_VISITABLE(OBJ)
Definition visitor_macros.hpp:117
#define LIEF_ELF_VISITABLE(OBJ)
Definition visitor_macros.hpp:43
#define LIEF_PE_FORWARD(OBJ)
Definition visitor_macros.hpp:23
#define LIEF_OAT_VISITABLE(OBJ)
Definition visitor_macros.hpp:72
#define LIEF_ELF_FORWARD(OBJ)
Definition visitor_macros.hpp:39