Add 'shell' and 'breakp' for the Python API

* 'lief.shell()' spawns an IPython interpreter with the current
     context
  * 'lief.breakp()' launchs pdb.set_trace()
This commit is contained in:
Romain Thomas
2017-11-01 15:01:52 +01:00
parent 5778bae34c
commit 49fdb8dc8f
2 changed files with 22 additions and 0 deletions
+8
View File
@@ -32,4 +32,12 @@ void init_LIEF_Parser_class(py::module& m) {
"Parse the given binary and return a " RST_CLASS_REF(lief.Binary) " object",
"raw"_a, "name"_a = "",
py::return_value_policy::take_ownership);
m.def("parse",
[] (py::object byteio) {
std::cout << "foo" << std::endl;
return nullptr;
},
py::return_value_policy::take_ownership);
}