Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for interfaces #890

Open
MOZGIII opened this issue Jan 5, 2023 · 0 comments
Open

Support for interfaces #890

MOZGIII opened this issue Jan 5, 2023 · 0 comments

Comments

@MOZGIII
Copy link

MOZGIII commented Jan 5, 2023

Sometimes you don't have a smart contract, but just a bare interface ABI you want to work with.

An example of the ABI spec:

[
    {
        "inputs": [
            {
                "internalType": "uint64",
                "name": "ticket",
                "type": "uint64"
            }
        ],
        "name": "check_payment",
        "outputs": [
            {
                "internalType": "bool",
                "name": "",
                "type": "bool"
            }
        ],
        "stateMutability": "view",
        "type": "function"
    }
]

This ABI spec requires the following declaration to function:

ethcontract::contract!("resources/abi.json", contract = CheckPayment);

Yet, the CheckPayment type is not generated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant