diff options
| author | Peter LaFosse <peter@vector35.com> | 2022-01-20 13:16:29 -0500 |
|---|---|---|
| committer | Peter LaFosse <peter@vector35.com> | 2022-01-20 13:16:29 -0500 |
| commit | 65c1ab279b34f11070a450de993886df9c7353ec (patch) | |
| tree | fff31eaca0be83e034f9356465b02f7224ce47a2 /python/function.py | |
| parent | b97912fbac14e760f1b595180ffe58af1ee34194 (diff) | |
Add support for mmlil_if_available
Diffstat (limited to 'python/function.py')
| -rw-r--r-- | python/function.py | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/python/function.py b/python/function.py index 8bfd2405..e328fd04 100644 --- a/python/function.py +++ b/python/function.py @@ -878,6 +878,19 @@ class Function: return mediumlevelil.MediumLevelILFunction(self.arch, result, self) @property + def mmlil(self) -> 'mediumlevelil.MediumLevelILFunction': + """Function mapped medium level IL (read-only)""" + return mediumlevelil.MediumLevelILFunction(self.arch, core.BNGetFunctionMappedMediumLevelIL(self.handle), self) + + @property + def mmlil_if_available(self) -> Optional['mediumlevelil.MediumLevelILFunction']: + """Function mapped medium level IL, or None if not loaded (read-only)""" + result = core.BNGetFunctionMappedMediumLevelILIfAvailable(self.handle) + if not result: + return None + return mediumlevelil.MediumLevelILFunction(self.arch, result, self) + + @property def high_level_il(self) -> 'highlevelil.HighLevelILFunction': """Function high level IL (read-only)""" return highlevelil.HighLevelILFunction(self.arch, core.BNGetFunctionHighLevelIL(self.handle), self) |
