mirror of
https://github.com/lief-project/LIEF
synced 2026-06-08 15:30:44 +00:00
Refactor some parts of the Architecture:
* JSON visitor are located in the format namespace * Visitor are *real* visitor * Visitable class has been renamed to Object * Due to a bug in Visual Studio 2015, we move to VS2017
This commit is contained in:
@@ -18,7 +18,7 @@
|
||||
|
||||
#include "pyELF.hpp"
|
||||
|
||||
#include "LIEF/visitors/Hash.hpp"
|
||||
#include "LIEF/ELF/hash.hpp"
|
||||
#include "LIEF/ELF/Header.hpp"
|
||||
|
||||
template<class T>
|
||||
@@ -32,9 +32,8 @@ void init_ELF_Header_class(py::module& m) {
|
||||
//
|
||||
// Header object
|
||||
//
|
||||
py::class_<Header>(m, "Header")
|
||||
py::class_<Header, LIEF::Object>(m, "Header")
|
||||
.def(py::init<>())
|
||||
.def(py::init<const std::vector<uint8_t>&>())
|
||||
|
||||
.def_property("identity_class",
|
||||
static_cast<getter_t<ELF_CLASS>>(&Header::identity_class),
|
||||
@@ -160,7 +159,7 @@ void init_ELF_Header_class(py::module& m) {
|
||||
.def("__ne__", &Header::operator!=)
|
||||
.def("__hash__",
|
||||
[] (const Header& header) {
|
||||
return LIEF::Hash::hash(header);
|
||||
return Hash::hash(header);
|
||||
})
|
||||
|
||||
.def("__contains__",
|
||||
|
||||
Reference in New Issue
Block a user