You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
error: cannot find derive macro `Deserialize` in this scope
--> src/model.rs:15:17
|
15 | #[derive(Debug, Deserialize, Clone)]
| ^^^^^^^^^^^
|
note: `Deserialize` is imported here, but it is only a trait, without a derive macro
--> src/model.rs:1:5
|
1 | use serde::Deserialize;
| ^^^^^^^^^^^^^^^^^^
Your repo shows this import as a feature inclusion;
serde = { version = "1", features = ["derive"] }
but this is never mentioned in the book afaict.
The text was updated successfully, but these errors were encountered:
At the moment I have no plan to change this, as I consider the GitHub repository as the source of truth for the code, while the book explains the code concepts.
The features feature was ruled out of scope of the book, but if more people report being confused, I may revisit this decision :)
My model.rs file is the same as https://github.com/skerkour/black-hat-rust/blob/main/ch_02/tricoder/src/model.rs
yet the compiler complains
Your repo shows this import as a feature inclusion;
but this is never mentioned in the book afaict.
The text was updated successfully, but these errors were encountered: