UNPKG

sevm

Version:

A Symbolic Ethereum Virtual Machine (EVM) bytecode decompiler & analyzer library & CLI

48 lines (47 loc) 1.44 kB
import type { State } from '../state'; import type { Inst, Expr, IInst } from '.'; import type { Sig } from './alu'; /** * Represents a jump from one `State` to another from the given `pc`. */ export declare class Branch { readonly pc: number; state: State<Inst, Expr>; constructor(pc: number, state: State<Inst, Expr>); static make(pc: number, state: State<Inst, Expr>): Branch; } export declare class Jump implements IInst { readonly offset: Expr; readonly destBranch: Branch; readonly name = "Jump"; constructor(offset: Expr, destBranch: Branch); eval(): this; next(): Branch[]; } export declare class Jumpi implements IInst { readonly cond: Expr; readonly offset: Expr; readonly fallBranch: Branch; readonly destBranch: Branch; readonly name = "Jumpi"; readonly evalCond: Expr; constructor(cond: Expr, offset: Expr, fallBranch: Branch, destBranch: Branch); eval(): Jumpi; next(): Branch[]; } export declare class JumpDest implements IInst { readonly fallBranch: Branch; readonly name = "JumpDest"; constructor(fallBranch: Branch); eval(): this; next(): Branch[]; } export declare class SigCase implements IInst { readonly condition: Sig; readonly offset: Expr; readonly fallBranch: Branch; readonly name = "SigCase"; constructor(condition: Sig, offset: Expr, fallBranch: Branch); eval(): this; next(): Branch[]; }