| 117 | |
| 118 | @dataclass(frozen=True) |
| 119 | class InstructionBranch: |
| 120 | type: BranchType |
| 121 | target: int |
| 122 | arch: Optional['Architecture'] |
| 123 | |
| 124 | def __repr__(self): |
| 125 | if self.arch is not None: |
| 126 | return f"<{self.type.name}: {self.arch.name}@{self.target:#x}>" |
| 127 | return f"<{self.type}: {self.target:#x}>" |
| 128 | |
| 129 | |
| 130 | @dataclass(frozen=False) |