oasisprotocol / oasisprotocol/oasis-core
support zero-argument RPC methods
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 369
- Forks
- 151
- Avg merge
- 1d 3h
- Merged PRs (30d)
- 6
Description
some contract methods do not require any parameters. We'd like the ability to define an api as follows:
contract_api! {
pub fn do_something() -> bool;
}
Currently the contract api fails to compile if any method has zero arity. A temporary workaround is to specify the empty protobuf in the signature, but this is undesirable since it adds unnecessary code.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the contract_api! entry point and inspect how method signatures with no parameters are handled. Confirm that a declaration such as do_something() -> bool compiles without an explicit empty protobuf, while preserving existing parameterized methods.
Written by the indexing model from the issue text.
Assessment
- Domain
- blockchain
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100