MCPcopy Create free account
hub / github.com/Vector35/binaryninja-api / disassembly_tokens

Method disassembly_tokens

python/binaryview.py:3878–3892  ·  view source on GitHub ↗
(
	    self, addr: int, arch: Optional['architecture.Architecture'] = None
	)

Source from the content-addressed store, hash-verified

3876 return True
3877
3878 def disassembly_tokens(
3879 self, addr: int, arch: Optional['architecture.Architecture'] = None
3880 ) -> Generator[Tuple[List['_function.InstructionTextToken'], int], None, None]:
3881 if arch is None:
3882 if self.arch is None:
3883 raise Exception("Can not call method disassembly with no Architecture specified")
3884 arch = self.arch
3885
3886 size = 1
3887 while size != 0:
3888 tokens, size = arch.get_instruction_text(self.read(addr, arch.max_instr_length), addr)
3889 addr += size
3890 if size == 0 or tokens is None:
3891 break
3892 yield (tokens, size)
3893
3894 def disassembly_text(self, addr: int,
3895 arch: Optional['architecture.Architecture'] = None) -> Generator[Tuple[str, int], None, None]:

Callers 1

Calls 2

readMethod · 0.95
get_instruction_textMethod · 0.45

Tested by

no test coverage detected