Skip to content

Commit

Permalink
adding mainExit as jump_type
Browse files Browse the repository at this point in the history
  • Loading branch information
tutugordillo committed Oct 22, 2024
1 parent ff1c434 commit 73dbcfb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/parser/cfg_block.py
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ def set_comes_from(self, new_comes_from: List[str]) -> None:
self._comes_from = new_comes_from

def set_jump_type(self, t: str) -> None:
if t not in ["conditional", "unconditional", "terminal", "falls_to", "sub_block"]:
if t not in ["conditional", "unconditional", "terminal", "falls_to", "sub_block", "mainExit"]:
raise Exception("Wrong jump type")
else:
self._jump_type = t
Expand Down Expand Up @@ -223,7 +223,7 @@ def set_jump_info(self, exit_info: Dict[str, Any]) -> None:
# It corresponds to falls_to blocks
self._jump_type = "falls_to"
elif type_block in ["MainExit"]:
self._jump_type = "terminal"
self._jump_type = "mainExit"
elif type_block in ["FunctionReturn"]:
self._jump_type = "FunctionReturn"
self._process_instructions_from_function_return(exit_info["returnValues"])
Expand Down

0 comments on commit 73dbcfb

Please sign in to comment.