1 #### Note: this error code is no longer emitted by the compiler.
3 You gave too many lifetime arguments. Erroneous code example:
9 f::<'static>() // error: wrong number of lifetime arguments:
10 // expected 0, found 1
14 Please check you give the right number of lifetime arguments. Example:
24 It's also important to note that the Rust compiler can generally
25 determine the lifetime by itself. Example:
33 // it can be written like this
34 fn get_value<'a>(&'a self) -> &'a str { &self.value }
35 // but the compiler works fine with this too:
36 fn without_lifetime(&self) -> &str { &self.value }
40 let f = Foo { value: "hello".to_owned() };
42 println!("{}", f.get_value());
43 println!("{}", f.without_lifetime());