for example,i have a strct field ” m_weather_forecast_samples: [WeatherForecastSample; 32] “,then when i build it,it will give me a error:
the trait bound `[WeatherForecastSample; 33]: Deserialize<'_>` is not satisfied
--> src\eventModel.rs:226:33
|
226 | m_weather_forecast_samples: [WeatherForecastSample; 33], // Array of weather forecast samples
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `Deserialize<'_>` is not implemented for `[WeatherForecastSample; 33]`
|
= help: the following other types implement trait `Deserialize<'de>`:
[T; 0]
[T; 1]
[T; 2]
[T; 3]
[T; 4]
[T; 5]
[T; 6]
[T; 7]
and 26 others
note: required by a bound in `next_element`
--> C:\Users\lc\.cargo\registry\src\index.crates.io-6f17d22bba15001f\serde-1.0.197\src\de\mod.rs:1726:12
|
1724 | fn next_element<T>(&mut self) -> Result<Option<T>, Self::Error>
| ------------ required by a bound in this associated function
1725 | where
1726 | T: Deserialize<'de>,
| ^^^^^^^^^^^^^^^^ required by this bound in `SeqAccess::next_element`
for example,i have a strct field ” m_weather_forecast_samples: [WeatherForecastSample; 32] “,then when i build it,it will give me a error:
what happen?