Module

contracts.rules_swap

Swap safety checks for broad inherited hx-target scopes.

Functions

collect_broad_targets 1 set[str]
Collect broad inherited hx-target values.
def collect_broad_targets(template_sources: dict[str, str]) -> set[str]
Parameters
Name Type Description
template_sources dict[str, str]
Returns
set[str]
check_swap_safety 1 list[ContractIssue]
Warn when mutating swaps may inherit broad container targets.
def check_swap_safety(template_sources: dict[str, str]) -> list[ContractIssue]
Parameters
Name Type Description
template_sources dict[str, str]
Returns
list[ContractIssue]