Skip to content

Commit 5ad2382

Browse files
committed
Fix tests
1 parent 5b53e4d commit 5ad2382

File tree

3 files changed

+26
-3
lines changed

3 files changed

+26
-3
lines changed

tests/ui/consts/const-eval/issue-50814.stderr

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,14 @@ note: erroneous constant encountered
1010
LL | &Sum::<U8, U8>::MAX
1111
| ^^^^^^^^^^^^^^^^^^
1212

13+
note: erroneous constant encountered
14+
--> $DIR/issue-50814.rs:21:6
15+
|
16+
LL | &Sum::<U8, U8>::MAX
17+
| ^^^^^^^^^^^^^^^^^^
18+
|
19+
= note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
20+
1321
error[E0080]: evaluation of `<Sum<U8, U8> as Unsigned>::MAX` failed
1422
--> $DIR/issue-50814.rs:15:21
1523
|

tests/ui/layout/post-mono-layout-cycle.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
//@ build-fail
2-
//~^ cycle detected when computing layout of `Wrapper<()>`
2+
//~^ ERROR: cycle detected when computing layout of
3+
//~| ERROR: cycle detected when computing layout of
34

45
trait Trait {
56
type Assoc;

tests/ui/layout/post-mono-layout-cycle.stderr

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,25 @@ error[E0391]: cycle detected when computing layout of `Wrapper<()>`
66
= 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
77

88
note: the above error was encountered while instantiating `fn indirect::<()>`
9-
--> $DIR/post-mono-layout-cycle.rs:23:5
9+
--> $DIR/post-mono-layout-cycle.rs:24:5
1010
|
1111
LL | indirect::<()>();
1212
| ^^^^^^^^^^^^^^^^
1313

14-
error: aborting due to 1 previous error
14+
error[E0391]: cycle detected when computing layout of `Wrapper<()>`
15+
|
16+
= note: ...which requires computing layout of `<() as Trait>::Assoc`...
17+
= note: ...which again requires computing layout of `Wrapper<()>`, completing the cycle
18+
= note: cycle used when computing layout of `core::option::Option<Wrapper<()>>`
19+
= 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
20+
= note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
21+
22+
note: the above error was encountered while instantiating `fn abi::<()>`
23+
--> $DIR/post-mono-layout-cycle.rs:20:5
24+
|
25+
LL | abi::<T>(None);
26+
| ^^^^^^^^^^^^^^
27+
28+
error: aborting due to 2 previous errors
1529

1630
For more information about this error, try `rustc --explain E0391`.

0 commit comments

Comments
 (0)