diff options
| author | Jordan Wiens <jordan@psifertex.com> | 2019-09-03 15:47:28 -0400 |
|---|---|---|
| committer | Jordan Wiens <jordan@psifertex.com> | 2019-09-03 15:47:28 -0400 |
| commit | cc850ebdf753a4fa8643e6b3e596d212251f010c (patch) | |
| tree | e1a83e7d1a0a8ecaa324891ecc2eaa73d5e14a55 /python/lowlevelil.py | |
| parent | e66693398775137273694ba394cd49dea8ae8981 (diff) | |
repr for llil and mlil blocks now uses decimal indexes to match the UI
Diffstat (limited to 'python/lowlevelil.py')
| -rw-r--r-- | python/lowlevelil.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/python/lowlevelil.py b/python/lowlevelil.py index 10bebcc5..b2379164 100644 --- a/python/lowlevelil.py +++ b/python/lowlevelil.py @@ -2891,6 +2891,13 @@ class LowLevelILBasicBlock(basicblock.BasicBlock): def __hash__(self): return hash((self.start, self.end, self._il_function)) + def __repr__(self): + arch = self.arch + if arch: + return "<llil block: %s@%d-%d>" % (arch.name, self.start, self.end) + else: + return "<llil block: %d-%d>" % (self.start, self.end) + def __contains__(self, instruction): if type(instruction) != LowLevelILInstruction or instruction.il_basic_block != self: return False |
