use schemars::JsonSchema;
#[derive(JsonSchema)]
pub enum MyEnum {}
error[E0282]: type annotations needed
--> src/main.rs:3:10
|
698 | #[derive(JsonSchema)]
| ^^^^^^^^^^ cannot infer type
|
= note: this error originates in the derive macro `JsonSchema` (in Nightly builds, run with -Z macro-backtrace for more info)
This code fails with version 0.8.18 of schemars:
Discovered from scale-info library: https://github.com/paritytech/scale-info/blob/3082edc2ae96de53c1ba104b8423451a9a485d1b/src/form.rs#L64-L67