Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR RUST

lifetime may not live long enough

fn returns_a_closure(&self,io: IO) -> Box<(dyn Fn() -> u64 + 'static)> {}

convert to:

fn returns_a_closure(&self,io: IO) -> Box<(dyn Fn() -> u64 + '_)> {}
 
PREVIOUS NEXT
Tagged: #lifetime #live #long
ADD COMMENT
Topic
Name
2+2 =