blob: 74b0541c01b2f68e867f8387f04ce74c0dc5c1e3 [file] [log] [blame]
error[E0597]: borrowed value does not live long enough
--> $DIR/issue-27592.rs:26:27
|
LL | write(|| format_args!("{}", String::from("Hello world")));
| ^^^^ -- temporary value needs to live until here
| | |
| | temporary value dropped here while still borrowed
| temporary value does not live long enough
error[E0597]: borrowed value does not live long enough
--> $DIR/issue-27592.rs:26:33
|
LL | write(|| format_args!("{}", String::from("Hello world")));
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^-- temporary value needs to live until here
| | |
| | temporary value dropped here while still borrowed
| temporary value does not live long enough
error: aborting due to 2 previous errors
For more information about this error, try `rustc --explain E0597`.