Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR RUST

armanriazi•rust•error•[E0106]: missing lifetime specifier --> src/main.rs:5:20 | 5 | fn dangle() -> &i32 { // dangle returns a reference to a String | ^ expected named lifetime parameter

help: consider using the `'static` lifetime
  |
5 |     fn dangle() -> &'static i32 { // dangle returns a reference to a String
 
PREVIOUS NEXT
Tagged: #missing #lifetime #specifier #fn #dangle #returns #reference #String #expected #named #lifetime #parameter
ADD COMMENT
Topic
Name
4+7 =