Whose Error Is It?
Rust printed this
error[E0106]: missing lifetime specifier
What it meansA function signature or struct holds a reference whose lifetime the compiler cannot infer, so you have to name the lifetime explicitly.
The first thing to checkAdd a lifetime parameter like <'a> and annotate the references with it, or return an owned type such as String instead of &str from the function.