Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 8a75209

Browse files
committedAug 6, 2023
Remove FIXME about NLL diagnostic that is already improved
The FIXME was added in 46984 when the diagnostic message looked like this: // FIXME(#46983): error message should be better &s.0 //~ ERROR free region `` does not outlive free region `'static` The message was improved in 90667 and now looks like this: &s.0 //~ ERROR lifetime may not live long enough but the FIXME was not removed. The issue 46983 about that diagnostics should be improved has been closed. We can remove the FIXME now.
1 parent 11467b1 commit 8a75209

File tree

2 files changed

+1
-3
lines changed

2 files changed

+1
-3
lines changed
 

‎tests/ui/nll/guarantor-issue-46974.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ fn foo(s: &mut (i32,)) -> i32 {
99
}
1010

1111
fn bar(s: &Box<(i32,)>) -> &'static i32 {
12-
// FIXME(#46983): error message should be better
1312
&s.0 //~ ERROR lifetime may not live long enough
1413
}
1514

‎tests/ui/nll/guarantor-issue-46974.stderr

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,10 @@ LL | *x
1010
| -- borrow later used here
1111

1212
error: lifetime may not live long enough
13-
--> $DIR/guarantor-issue-46974.rs:13:5
13+
--> $DIR/guarantor-issue-46974.rs:12:5
1414
|
1515
LL | fn bar(s: &Box<(i32,)>) -> &'static i32 {
1616
| - let's call the lifetime of this reference `'1`
17-
LL | // FIXME(#46983): error message should be better
1817
LL | &s.0
1918
| ^^^^ returning this value requires that `'1` must outlive `'static`
2019

0 commit comments

Comments
 (0)
Please sign in to comment.