Skip to content

Commit 9e03d7d

Browse files
committed
Add known-bug directive to issue #47511 test case
1 parent 1b14fd3 commit 9e03d7d

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

src/test/ui/issues/issue-47511.rs

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,15 @@
1+
// check-fail
2+
// known-bug
3+
14
// Regression test for #47511: anonymous lifetimes can appear
25
// unconstrained in a return type, but only if they appear just once
36
// in the input, as the input to a projection.
47

58
fn f(_: X) -> X {
6-
//~^ ERROR return type references an anonymous lifetime
79
unimplemented!()
810
}
911

1012
fn g<'a>(_: X<'a>) -> X<'a> {
11-
//~^ ERROR return type references lifetime `'a`, which is not constrained
1213
unimplemented!()
1314
}
1415

src/test/ui/issues/issue-47511.stderr

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
error[E0581]: return type references an anonymous lifetime, which is not constrained by the fn input types
2-
--> $DIR/issue-47511.rs:5:15
2+
--> $DIR/issue-47511.rs:8:15
33
|
44
LL | fn f(_: X) -> X {
55
| ^
66
|
77
= note: lifetimes appearing in an associated type are not considered constrained
88

99
error[E0581]: return type references lifetime `'a`, which is not constrained by the fn input types
10-
--> $DIR/issue-47511.rs:10:23
10+
--> $DIR/issue-47511.rs:12:23
1111
|
1212
LL | fn g<'a>(_: X<'a>) -> X<'a> {
1313
| ^^^^^

0 commit comments

Comments
 (0)