Make `decl_runtime_apis!` fail on methods with default implementation (#7371)
* Make `decl_runtime_apis!` fail on methods with default implementation Runtime api functions are not allowed to have default implementations. This fixes this by throwing an error when we detect such a function. * Update primitives/api/proc-macro/src/decl_runtime_apis.rs Co-authored-by:André Silva <123550+andresilva@users.noreply.github.com> * Update primitives/api/test/tests/ui/no_default_implementation.stderr Co-authored-by:
André Silva <123550+andresilva@users.noreply.github.com>
Showing
- substrate/primitives/api/proc-macro/src/decl_runtime_apis.rs 7 additions, 0 deletionssubstrate/primitives/api/proc-macro/src/decl_runtime_apis.rs
- substrate/primitives/api/test/tests/ui/no_default_implementation.rs 9 additions, 0 deletions...primitives/api/test/tests/ui/no_default_implementation.rs
- substrate/primitives/api/test/tests/ui/no_default_implementation.stderr 8 additions, 0 deletions...itives/api/test/tests/ui/no_default_implementation.stderr
Please register or sign in to comment