Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pysoot/sootir/soot_block.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

@dataclass(slots=True, unsafe_hash=True)
class SootBlock:
label: str
label: int
statements: tuple[SootStmt, ...]
idx: int | None

Expand Down
14 changes: 7 additions & 7 deletions pysoot/sootir/soot_statement.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ def from_ir(label, offset, ir_stmt, stmt_map=None):

@dataclass(slots=True, unsafe_hash=True)
class GotoStmt(SootStmt):
target: SootStmt
target: int

def __str__(self):
return f"goto {self.target}"
Expand All @@ -117,7 +117,7 @@ def from_ir(label, offset, ir_stmt, stmt_map=None):
@dataclass(slots=True, unsafe_hash=True)
class IfStmt(SootStmt):
condition: SootValue
target: SootStmt
target: int

def __str__(self):
return f"if({str(self.condition)}) goto {str(self.target)}"
Expand Down Expand Up @@ -169,8 +169,8 @@ def from_ir(label, offset, ir_stmt, stmt_map=None):
@dataclass(slots=True, unsafe_hash=True)
class LookupSwitchStmt(SootStmt):
key: SootValue
lookup_values_and_targets: frozendict[int, SootStmt]
default_target: SootStmt
lookup_values_and_targets: frozendict[int, int]
default_target: int

def __str__(self):
targets = repr(self.lookup_values_and_targets)
Expand All @@ -197,9 +197,9 @@ class TableSwitchStmt(SootStmt):
key: SootValue
low_index: int
high_index: int
targets: tuple[SootStmt, ...]
lookup_values_and_targets: frozendict[int, SootStmt]
default_target: SootStmt
targets: tuple[int, ...]
lookup_values_and_targets: frozendict[int, int]
default_target: int

def __str__(self):
targets = repr(self.lookup_values_and_targets)
Expand Down
Loading