validate_erc_nep_patterns

Function validate_erc_nep_patterns 

Source
fn validate_erc_nep_patterns(
    metadata: &ContractMetadata,
    diagnostics: &mut Vec<Diagnostic>,
)
Expand description

ERC → NEP pattern adaptation diagnostics.

Detects Ethereum-style patterns in Solidity contracts and emits warnings with actionable guidance for migrating to Neo N3 equivalents.

Checked patterns:

  • ERC-20 transfer(to, amount) → NEP-17 transfer(from, to, amount, data)
  • ERC-20 approve/allowance/transferFrom → not in NEP-17 spec
  • ERC-721 transferFrom(from, to, tokenId) → NEP-11 transfer(to, tokenId, data)
  • receive() / fallback()onNEP17Payment() callback
  • supportsInterface(bytes4) → manifest supportedstandards