From 5b575ff6a87061221e1c17824b2b42af839ccc74 Mon Sep 17 00:00:00 2001 From: Brian Potchik Date: Tue, 8 Jul 2025 12:13:19 -0400 Subject: Various improvements for guided disassembly mode. --- python/function.py | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'python/function.py') diff --git a/python/function.py b/python/function.py index 37bd3396..9ea8093b 100644 --- a/python/function.py +++ b/python/function.py @@ -2326,6 +2326,22 @@ class Function: address_list[i].address = addresses[i][1] core.BNRemoveGuidedSourceBlocks(self.handle, address_list, len(addresses)) + def is_guided_source_block( + self, arch: 'architecture.Architecture', addr: int + ) -> bool: + """ + ``is_guided_source_block`` checks if the given address is a guided source block. + + :param architecture.Architecture arch: Architecture of the address to check + :param int addr: Address to check + :rtype: bool + :Example: + + >>> current_function.is_guided_source_block(arch, 0x400000) + True + """ + return core.BNIsGuidedSourceBlock(self.handle, arch.handle, addr) + def get_guided_source_blocks( self ) -> List[Tuple['architecture.Architecture', int]]: -- cgit v1.3.1