From 8849fb2b2b8dc824bd3f17ce1026a04856477a94 Mon Sep 17 00:00:00 2001 From: Jordan Wiens Date: Sun, 4 Mar 2018 18:08:04 -0500 Subject: working division, prints, and metaclasses, but imports broken, still needs work --- python/demangle.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'python/demangle.py') diff --git a/python/demangle.py b/python/demangle.py index 11673263..50322694 100644 --- a/python/demangle.py +++ b/python/demangle.py @@ -20,9 +20,8 @@ import ctypes -# Binary Ninja components -import _binaryninjacore as core -import types +# Binary Ninja components -- additional imports belong in the appropriate class +from binaryninja import _binaryninjacore as core def get_qualified_name(names): @@ -56,6 +55,7 @@ def demangle_ms(arch, mangled_name): (, ['Foobar', 'testf']) >>> """ + from binaryninja import types handle = ctypes.POINTER(core.BNType)() outName = ctypes.POINTER(ctypes.c_char_p)() outSize = ctypes.c_ulonglong() @@ -69,6 +69,7 @@ def demangle_ms(arch, mangled_name): def demangle_gnu3(arch, mangled_name): + from binaryninja import types handle = ctypes.POINTER(core.BNType)() outName = ctypes.POINTER(ctypes.c_char_p)() outSize = ctypes.c_ulonglong() -- cgit v1.3.1