Enable to add relocation associated with symbol

Resolve #184
This commit is contained in:
Romain Thomas
2018-06-19 09:59:29 +02:00
parent cd9cb41687
commit a9f3cb8f9b
6 changed files with 255 additions and 57 deletions
+3 -2
View File
@@ -68,10 +68,11 @@ void create<Relocation>(py::module& m) {
&Relocation::has_symbol,
"``True`` if a " RST_CLASS_REF(lief.ELF.Symbol) " is associated with the relocations")
.def_property_readonly("symbol",
.def_property("symbol",
static_cast<Symbol& (Relocation::*)(void)>(&Relocation::symbol),
static_cast<void (Relocation::*)(Symbol*)>(&Relocation::symbol),
"" RST_CLASS_REF(lief.ELF.Symbol) " associated with the relocation",
py::return_value_policy::reference_internal)
py::return_value_policy::reference)
.def_property_readonly("has_section",
&Relocation::has_section,