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
In order to match in templates, std::ops::Deref must be in scope.
Otherwise, confusing errors abound:
error[E0599]: no method named `deref` found for type `&std::option::Option<std::string::String>` in the current scope
--> webserver/src/routes/web/base.rs:7:10
|
7 | #[derive(Template)]
| ^^^^^^^^
|
= help: items from traits can only be used if the trait is in scope
= note: the following trait is implemented but not in scope, perhaps add a `use` for it:
`use lazy_static::Deref;`
This issue is two-part:
I don't think this should be necessary. The more imports that have seemingly no use in the actual code, the less clear the code is.
Until it isn't necessary, it should be documented.
The text was updated successfully, but these errors were encountered:
In order to match in templates,
std::ops::Deref
must be in scope.Otherwise, confusing errors abound:
This issue is two-part:
The text was updated successfully, but these errors were encountered: