From c80542f9836e38563ca7a4efc87916959c4a0c73 Mon Sep 17 00:00:00 2001 From: KyleMiles Date: Sat, 22 Jul 2023 21:53:19 -0400 Subject: Add Variable.is_parameter_variable --- python/variable.py | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'python') diff --git a/python/variable.py b/python/variable.py index 1ea4728e..ee96cb46 100644 --- a/python/variable.py +++ b/python/variable.py @@ -833,6 +833,11 @@ class Variable(CoreVariable): def dead_store_elimination(self, value): core.BNSetFunctionVariableDeadStoreElimination(self._function.handle, self.to_BNVariable(), value) + @property + def is_parameter_variable(self) -> bool: + """returns whether this variable is a function parameter""" + return self in self._function.parameter_vars + @property def offset_to_next_variable(self) -> Optional[int]: """returns number of bytes to the next variable on the stack""" -- cgit v1.3.1