Source code

Revision control

Copy as Markdown

Other Tools

error[E0308]: mismatched types
--> tests/compile-fail/default_expr_wrong_type.rs:5:25
|
5 | #[darling(default = "usize::default")]
| ^^^^^^^^^^^^^^^^ expected struct `String`, found `usize`
|
help: try using a conversion method
|
5 | #[darling(default = "usize::default".to_string())]
| ++++++++++++
5 | #[darling(default = "usize::default".to_string())]
| ++++++++++++
error[E0308]: mismatched types
--> tests/compile-fail/default_expr_wrong_type.rs:8:35
|
8 | #[darling(multiple, default = "usize::default")]
| ^^^^^^^^^^^^^^^^ expected struct `Vec`, found `usize`
|
= note: expected struct `Vec<String>`
found type `usize`