2023-03-10 09:51:03 +01:00
|
|
|
error[E0277]: the trait bound `for<'de> Struct: serde::de::Deserialize<'de>` is not satisfied
|
2024-03-14 21:19:03 +01:00
|
|
|
--> tests/debug_handler/fail/json_not_deserialize.rs:7:24
|
2023-03-10 09:51:03 +01:00
|
|
|
|
|
2024-03-14 21:19:03 +01:00
|
|
|
7 | async fn handler(_foo: Json<Struct>) {}
|
|
|
|
| ^^^^^^^^^^^^ the trait `for<'de> serde::de::Deserialize<'de>` is not implemented for `Struct`, which is required by `Json<Struct>: FromRequest<()>`
|
2023-03-10 09:51:03 +01:00
|
|
|
|
|
2024-07-09 23:08:59 +02:00
|
|
|
= note: for local types consider adding `#[derive(serde::Deserialize)]` to your `Struct` type
|
|
|
|
= note: for types from other crates check whether the crate offers a `serde` feature flag
|
2023-03-10 09:51:03 +01:00
|
|
|
= help: the following other types implement trait `serde::de::Deserialize<'de>`:
|
2023-09-29 09:25:26 +02:00
|
|
|
bool
|
|
|
|
char
|
|
|
|
isize
|
|
|
|
i8
|
|
|
|
i16
|
|
|
|
i32
|
|
|
|
i64
|
|
|
|
i128
|
2023-03-10 09:51:03 +01:00
|
|
|
and $N others
|
|
|
|
= note: required for `Struct` to implement `serde::de::DeserializeOwned`
|
2023-03-12 16:37:32 +01:00
|
|
|
= note: required for `Json<Struct>` to implement `FromRequest<()>`
|
2023-03-10 09:51:03 +01:00
|
|
|
= help: see issue #48214
|
|
|
|
= help: add `#![feature(trivial_bounds)]` to the crate attributes to enable
|
2024-03-14 21:19:03 +01:00
|
|
|
|
|
|
|
error[E0277]: the trait bound `for<'de> Struct: serde::de::Deserialize<'de>` is not satisfied
|
|
|
|
--> tests/debug_handler/fail/json_not_deserialize.rs:7:24
|
|
|
|
|
|
|
|
|
7 | async fn handler(_foo: Json<Struct>) {}
|
|
|
|
| ^^^^^^^^^^^^ the trait `for<'de> serde::de::Deserialize<'de>` is not implemented for `Struct`, which is required by `Json<Struct>: FromRequest<()>`
|
|
|
|
|
|
2024-07-09 23:08:59 +02:00
|
|
|
= note: for local types consider adding `#[derive(serde::Deserialize)]` to your `Struct` type
|
|
|
|
= note: for types from other crates check whether the crate offers a `serde` feature flag
|
2024-03-14 21:19:03 +01:00
|
|
|
= help: the following other types implement trait `serde::de::Deserialize<'de>`:
|
|
|
|
bool
|
|
|
|
char
|
|
|
|
isize
|
|
|
|
i8
|
|
|
|
i16
|
|
|
|
i32
|
|
|
|
i64
|
|
|
|
i128
|
|
|
|
and $N others
|
|
|
|
= note: required for `Struct` to implement `serde::de::DeserializeOwned`
|
|
|
|
= note: required for `Json<Struct>` to implement `FromRequest<()>`
|
|
|
|
note: required by a bound in `__axum_macros_check_handler_0_from_request_check`
|
|
|
|
--> tests/debug_handler/fail/json_not_deserialize.rs:7:24
|
|
|
|
|
|
|
|
|
7 | async fn handler(_foo: Json<Struct>) {}
|
|
|
|
| ^^^^^^^^^^^^ required by this bound in `__axum_macros_check_handler_0_from_request_check`
|