-
Notifications
You must be signed in to change notification settings - Fork 120
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Expected struct <FOOBAR>, found <OTHER_LAZY_STATIC_REF> #119
Comments
Hi @jens1o! the problem here is that each lazy_static! {
static ref FIREFOX_REGEX: Regex = { Regex::new(r"firefox/([\d\.]+)").unwrap() };
static ref EDGE_REGEX: Regex = { Regex::new(r"edge/(\d{2}\.\d+)").unwrap() };
static ref BROWSER_LIST: HashMap<&'static str, &'static Regex> = {
let mut m = HashMap::new();
m.insert("Firefox", &*FIREFOX_REGEX);
m.insert("Edge", &*EDGE_REGEX);
m
};
} |
Oh okay. Is it possible to make the error message more clearer? Thanks! |
It's a bit confusing, isn't it. I think the best way we could improve the error messages here is by requiring the actual type name in the |
I don't understand that.
I don't understand that.
The text was updated successfully, but these errors were encountered: