diff options
| author | Peter LaFosse <peter@vector35.com> | 2021-06-23 20:20:50 -0400 |
|---|---|---|
| committer | Peter LaFosse <peter@vector35.com> | 2021-09-05 10:09:09 -0400 |
| commit | bc5c0977dc5b4087e8f39cc67089bb5709aac04e (patch) | |
| tree | 2e955215d9a9000a84412f814d011248f6bdbe5d /python/basicblock.py | |
| parent | 421b398453d09e06e7b202229e34b66414683a45 (diff) | |
type hints for highlevelil.py, mediumlevelil.py and lowlevelil.py, workflow.py
Fix linter error in scriptingprovider.py
Update workflow.py using updated paradigms and type hints
Diffstat (limited to 'python/basicblock.py')
| -rw-r--r-- | python/basicblock.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/python/basicblock.py b/python/basicblock.py index 7104f418..4aca6de5 100644 --- a/python/basicblock.py +++ b/python/basicblock.py @@ -51,7 +51,8 @@ class BasicBlockEdge: class BasicBlock: def __init__(self, handle:core.BNBasicBlockHandle, view:Optional['binaryninja.binaryview.BinaryView']=None): self._view = view - self.handle = core.handle_of_type(handle, core.BNBasicBlock) + _handle = core.BNBasicBlockHandle + self.handle:core.BNBasicBlockHandle = ctypes.cast(handle, _handle) self._arch = None self._func = None self._instStarts:Optional[List[int]] = None @@ -144,7 +145,7 @@ class BasicBlock: self._instStarts.append(start) start += length - def _create_instance(self, handle:core.BNBasicBlock, view:'binaryninja.binaryview.BinaryView') -> 'BasicBlock': + def _create_instance(self, handle:core.BNBasicBlockHandle, view:'binaryninja.binaryview.BinaryView') -> 'BasicBlock': """Internal method used to instantiate child instances""" return BasicBlock(handle, view) |
