1
- error[E0391]: cycle detected when computing type of `opaque::<impl at $DIR/unsupported.rs:25 :5: 25 :24>::{synthetic#0}`
2
- --> $DIR/unsupported.rs:26 :25
1
+ error[E0391]: cycle detected when computing type of `opaque::<impl at $DIR/unsupported.rs:21 :5: 21 :24>::{synthetic#0}`
2
+ --> $DIR/unsupported.rs:22 :25
3
3
|
4
4
LL | reuse to_reuse::opaque_ret;
5
5
| ^^^^^^^^^^
6
6
|
7
7
note: ...which requires comparing an impl and trait method signature, inferring any hidden `impl Trait` types in the process...
8
- --> $DIR/unsupported.rs:26 :25
8
+ --> $DIR/unsupported.rs:22 :25
9
9
|
10
10
LL | reuse to_reuse::opaque_ret;
11
11
| ^^^^^^^^^^
12
- = note: ...which again requires computing type of `opaque::<impl at $DIR/unsupported.rs:25 :5: 25 :24>::{synthetic#0}`, completing the cycle
13
- note: cycle used when checking that `opaque::<impl at $DIR/unsupported.rs:25 :5: 25 :24>` is well-formed
14
- --> $DIR/unsupported.rs:25 :5
12
+ = note: ...which again requires computing type of `opaque::<impl at $DIR/unsupported.rs:21 :5: 21 :24>::{synthetic#0}`, completing the cycle
13
+ note: cycle used when checking that `opaque::<impl at $DIR/unsupported.rs:21 :5: 21 :24>` is well-formed
14
+ --> $DIR/unsupported.rs:21 :5
15
15
|
16
16
LL | impl ToReuse for u8 {
17
17
| ^^^^^^^^^^^^^^^^^^^
18
18
= note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
19
19
20
- warning: this function depends on never type fallback being `()`
21
- --> $DIR/unsupported.rs:13:9
22
- |
23
- LL | pub fn opaque_ret() -> impl Trait { unimplemented!() }
24
- | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
25
- |
26
- = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
27
- = note: for more information, see issue #123748 <https://github.com/rust-lang/rust/issues/123748>
28
- = help: specify the types explicitly
29
- note: in edition 2024, the requirement `!: opaque::Trait` will fail
30
- --> $DIR/unsupported.rs:13:32
31
- |
32
- LL | pub fn opaque_ret() -> impl Trait { unimplemented!() }
33
- | ^^^^^^^^^^
34
- = note: `#[warn(dependency_on_unit_never_type_fallback)]` on by default
35
-
36
- warning: this function depends on never type fallback being `()`
37
- --> $DIR/unsupported.rs:19:9
38
- |
39
- LL | fn opaque_ret() -> impl Trait { unimplemented!() }
40
- | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
41
- |
42
- = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
43
- = note: for more information, see issue #123748 <https://github.com/rust-lang/rust/issues/123748>
44
- = help: specify the types explicitly
45
- note: in edition 2024, the requirement `!: opaque::Trait` will fail
46
- --> $DIR/unsupported.rs:19:28
47
- |
48
- LL | fn opaque_ret() -> impl Trait { unimplemented!() }
49
- | ^^^^^^^^^^
50
-
51
- error[E0391]: cycle detected when computing type of `opaque::<impl at $DIR/unsupported.rs:28:5: 28:25>::{synthetic#0}`
52
- --> $DIR/unsupported.rs:29:24
20
+ error[E0391]: cycle detected when computing type of `opaque::<impl at $DIR/unsupported.rs:24:5: 24:25>::{synthetic#0}`
21
+ --> $DIR/unsupported.rs:25:24
53
22
|
54
23
LL | reuse ToReuse::opaque_ret;
55
24
| ^^^^^^^^^^
56
25
|
57
26
note: ...which requires comparing an impl and trait method signature, inferring any hidden `impl Trait` types in the process...
58
- --> $DIR/unsupported.rs:29 :24
27
+ --> $DIR/unsupported.rs:25 :24
59
28
|
60
29
LL | reuse ToReuse::opaque_ret;
61
30
| ^^^^^^^^^^
62
- = note: ...which again requires computing type of `opaque::<impl at $DIR/unsupported.rs:28 :5: 28 :25>::{synthetic#0}`, completing the cycle
63
- note: cycle used when checking that `opaque::<impl at $DIR/unsupported.rs:28 :5: 28 :25>` is well-formed
64
- --> $DIR/unsupported.rs:28 :5
31
+ = note: ...which again requires computing type of `opaque::<impl at $DIR/unsupported.rs:24 :5: 24 :25>::{synthetic#0}`, completing the cycle
32
+ note: cycle used when checking that `opaque::<impl at $DIR/unsupported.rs:24 :5: 24 :25>` is well-formed
33
+ --> $DIR/unsupported.rs:24 :5
65
34
|
66
35
LL | impl ToReuse for u16 {
67
36
| ^^^^^^^^^^^^^^^^^^^^
68
37
= note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
69
38
70
39
error: recursive delegation is not supported yet
71
- --> $DIR/unsupported.rs:42 :22
40
+ --> $DIR/unsupported.rs:38 :22
72
41
|
73
42
LL | pub reuse to_reuse2::foo;
74
43
| --- callee defined here
@@ -77,14 +46,14 @@ LL | reuse to_reuse1::foo;
77
46
| ^^^
78
47
79
48
error[E0283]: type annotations needed
80
- --> $DIR/unsupported.rs:52 :18
49
+ --> $DIR/unsupported.rs:48 :18
81
50
|
82
51
LL | reuse Trait::foo;
83
52
| ^^^ cannot infer type
84
53
|
85
54
= note: cannot satisfy `_: effects::Trait`
86
55
87
- error: aborting due to 4 previous errors; 2 warnings emitted
56
+ error: aborting due to 4 previous errors
88
57
89
58
Some errors have detailed explanations: E0283, E0391.
90
59
For more information about an error, try `rustc --explain E0283`.
0 commit comments