Skip to content

Commit 4ff65ec

Browse files
committed
Fmt and test revert
1 parent 8ad7e56 commit 4ff65ec

File tree

4 files changed

+39
-38
lines changed

4 files changed

+39
-38
lines changed

compiler/rustc_middle/src/ty/fold.rs

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -879,14 +879,14 @@ impl<'tcx> TypeVisitor<'tcx> for ValidateBoundVars<'tcx> {
879879
if kind != bound_ty.kind {
880880
bug!(
881881
"Mismatched type kinds: {:?} doesn't var in list {:?}",
882-
bound_ty.kind, list_var
882+
bound_ty.kind,
883+
list_var
883884
);
884885
}
885886
}
886-
_ => bug!(
887-
"Mismatched bound variable kinds! Expected type, found {:?}",
888-
list_var
889-
),
887+
_ => {
888+
bug!("Mismatched bound variable kinds! Expected type, found {:?}", list_var)
889+
}
890890
}
891891
}
892892

@@ -908,7 +908,9 @@ impl<'tcx> TypeVisitor<'tcx> for ValidateBoundVars<'tcx> {
908908
if kind != br.kind {
909909
bug!(
910910
"Mismatched region kinds: {:?} doesn't match var ({:?}) in list ({:?})",
911-
br.kind, list_var, self.bound_vars
911+
br.kind,
912+
list_var,
913+
self.bound_vars
912914
);
913915
}
914916
}

src/test/ui/symbol-names/impl1.legacy.stderr

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,71 +1,71 @@
1-
error: symbol-name(_ZN5impl13foo3Foo3bar17h2e76f87b171019e0E)
2-
--> $DIR/impl1.rs:16:9
1+
error: symbol-name(_ZN5impl13foo3Foo3bar17<SYMBOL_HASH>)
2+
--> $DIR/impl1.rs:15:9
33
|
44
LL | #[rustc_symbol_name]
55
| ^^^^^^^^^^^^^^^^^^^^
66

7-
error: demangling(impl1::foo::Foo::bar::h2e76f87b171019e0)
8-
--> $DIR/impl1.rs:16:9
7+
error: demangling(impl1::foo::Foo::bar::<SYMBOL_HASH>)
8+
--> $DIR/impl1.rs:15:9
99
|
1010
LL | #[rustc_symbol_name]
1111
| ^^^^^^^^^^^^^^^^^^^^
1212

1313
error: demangling-alt(impl1::foo::Foo::bar)
14-
--> $DIR/impl1.rs:16:9
14+
--> $DIR/impl1.rs:15:9
1515
|
1616
LL | #[rustc_symbol_name]
1717
| ^^^^^^^^^^^^^^^^^^^^
1818

1919
error: def-path(foo::Foo::bar)
20-
--> $DIR/impl1.rs:23:9
20+
--> $DIR/impl1.rs:22:9
2121
|
2222
LL | #[rustc_def_path]
2323
| ^^^^^^^^^^^^^^^^^
2424

25-
error: symbol-name(_ZN5impl13bar33_$LT$impl$u20$impl1..foo..Foo$GT$3baz17hb388a171ee84bca1E)
26-
--> $DIR/impl1.rs:34:9
25+
error: symbol-name(_ZN5impl13bar33_$LT$impl$u20$impl1..foo..Foo$GT$3baz17<SYMBOL_HASH>)
26+
--> $DIR/impl1.rs:33:9
2727
|
2828
LL | #[rustc_symbol_name]
2929
| ^^^^^^^^^^^^^^^^^^^^
3030

31-
error: demangling(impl1::bar::<impl impl1::foo::Foo>::baz::hb388a171ee84bca1)
32-
--> $DIR/impl1.rs:34:9
31+
error: demangling(impl1::bar::<impl impl1::foo::Foo>::baz::<SYMBOL_HASH>)
32+
--> $DIR/impl1.rs:33:9
3333
|
3434
LL | #[rustc_symbol_name]
3535
| ^^^^^^^^^^^^^^^^^^^^
3636

3737
error: demangling-alt(impl1::bar::<impl impl1::foo::Foo>::baz)
38-
--> $DIR/impl1.rs:34:9
38+
--> $DIR/impl1.rs:33:9
3939
|
4040
LL | #[rustc_symbol_name]
4141
| ^^^^^^^^^^^^^^^^^^^^
4242

4343
error: def-path(bar::<impl foo::Foo>::baz)
44-
--> $DIR/impl1.rs:41:9
44+
--> $DIR/impl1.rs:40:9
4545
|
4646
LL | #[rustc_def_path]
4747
| ^^^^^^^^^^^^^^^^^
4848

49-
error: symbol-name(_ZN209_$LT$$u5b$$RF$dyn$u20$impl1..Foo$u2b$Assoc$u20$$u3d$$u20$extern$u20$$u22$C$u22$$u20$fn$LP$$RF$u8$C$$u20$...$RP$$u2b$impl1..AutoTrait$u3b$$u20$3$u5d$$u20$as$u20$impl1..main..$u7b$$u7b$closure$u7d$$u7d$..Bar$GT$6method17SYMBOL_HASH)
50-
--> $DIR/impl1.rs:64:13
49+
error: symbol-name(_ZN209_$LT$$u5b$$RF$dyn$u20$impl1..Foo$u2b$Assoc$u20$$u3d$$u20$extern$u20$$u22$C$u22$$u20$fn$LP$$RF$u8$C$$u20$...$RP$$u2b$impl1..AutoTrait$u3b$$u20$3$u5d$$u20$as$u20$impl1..main..$u7b$$u7b$closure$u7d$$u7d$..Bar$GT$6method17<SYMBOL_HASH>)
50+
--> $DIR/impl1.rs:63:13
5151
|
5252
LL | #[rustc_symbol_name]
5353
| ^^^^^^^^^^^^^^^^^^^^
5454

55-
error: demangling(<[&dyn impl1::Foo+Assoc = extern "C" fn(&u8, ::.)+impl1::AutoTrait; 3] as impl1::main::{{closure}}::Bar>::method::SYMBOL_HASH)
56-
--> $DIR/impl1.rs:64:13
55+
error: demangling(<[&dyn impl1::Foo+Assoc = extern "C" fn(&u8, ::.)+impl1::AutoTrait; 3] as impl1::main::{{closure}}::Bar>::method::<SYMBOL_HASH>)
56+
--> $DIR/impl1.rs:63:13
5757
|
5858
LL | #[rustc_symbol_name]
5959
| ^^^^^^^^^^^^^^^^^^^^
6060

6161
error: demangling-alt(<[&dyn impl1::Foo+Assoc = extern "C" fn(&u8, ::.)+impl1::AutoTrait; 3] as impl1::main::{{closure}}::Bar>::method)
62-
--> $DIR/impl1.rs:64:13
62+
--> $DIR/impl1.rs:63:13
6363
|
6464
LL | #[rustc_symbol_name]
6565
| ^^^^^^^^^^^^^^^^^^^^
6666

6767
error: def-path(<[&dyn Foo<Assoc = for<'r> extern "C" fn(&'r u8, ...)> + AutoTrait; 3] as main::{closure#1}::Bar>::method)
68-
--> $DIR/impl1.rs:71:13
68+
--> $DIR/impl1.rs:70:13
6969
|
7070
LL | #[rustc_def_path]
7171
| ^^^^^^^^^^^^^^^^^

src/test/ui/symbol-names/impl1.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,7 @@
33
// revisions: legacy v0
44
//[legacy]compile-flags: -Z symbol-mangling-version=legacy
55
//[v0]compile-flags: -Z symbol-mangling-version=v0
6-
//[legacy]normalize-stderr-test: "method17h[\d\w]+" -> "method17SYMBOL_HASH"
7-
//[legacy]normalize-stderr-test: "method::h[\d\w]+" -> "method::SYMBOL_HASH"
6+
//[legacy]normalize-stderr-test: "h[\w]{16}E?\)" -> "<SYMBOL_HASH>)"
87

98
#![feature(auto_traits, rustc_attrs)]
109
#![allow(dead_code)]

src/test/ui/symbol-names/impl1.v0.stderr

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,71 +1,71 @@
11
error: symbol-name(_RNvMNtCs21hi0yVfW1J_5impl13fooNtB2_3Foo3bar)
2-
--> $DIR/impl1.rs:16:9
2+
--> $DIR/impl1.rs:15:9
33
|
44
LL | #[rustc_symbol_name]
55
| ^^^^^^^^^^^^^^^^^^^^
66

77
error: demangling(<impl1[17891616a171812d]::foo::Foo>::bar)
8-
--> $DIR/impl1.rs:16:9
8+
--> $DIR/impl1.rs:15:9
99
|
1010
LL | #[rustc_symbol_name]
1111
| ^^^^^^^^^^^^^^^^^^^^
1212

1313
error: demangling-alt(<impl1::foo::Foo>::bar)
14-
--> $DIR/impl1.rs:16:9
14+
--> $DIR/impl1.rs:15:9
1515
|
1616
LL | #[rustc_symbol_name]
1717
| ^^^^^^^^^^^^^^^^^^^^
1818

1919
error: def-path(foo::Foo::bar)
20-
--> $DIR/impl1.rs:23:9
20+
--> $DIR/impl1.rs:22:9
2121
|
2222
LL | #[rustc_def_path]
2323
| ^^^^^^^^^^^^^^^^^
2424

2525
error: symbol-name(_RNvMNtCs21hi0yVfW1J_5impl13barNtNtB4_3foo3Foo3baz)
26-
--> $DIR/impl1.rs:34:9
26+
--> $DIR/impl1.rs:33:9
2727
|
2828
LL | #[rustc_symbol_name]
2929
| ^^^^^^^^^^^^^^^^^^^^
3030

3131
error: demangling(<impl1[17891616a171812d]::foo::Foo>::baz)
32-
--> $DIR/impl1.rs:34:9
32+
--> $DIR/impl1.rs:33:9
3333
|
3434
LL | #[rustc_symbol_name]
3535
| ^^^^^^^^^^^^^^^^^^^^
3636

3737
error: demangling-alt(<impl1::foo::Foo>::baz)
38-
--> $DIR/impl1.rs:34:9
38+
--> $DIR/impl1.rs:33:9
3939
|
4040
LL | #[rustc_symbol_name]
4141
| ^^^^^^^^^^^^^^^^^^^^
4242

4343
error: def-path(bar::<impl foo::Foo>::baz)
44-
--> $DIR/impl1.rs:41:9
44+
--> $DIR/impl1.rs:40:9
4545
|
4646
LL | #[rustc_def_path]
4747
| ^^^^^^^^^^^^^^^^^
4848

4949
error: symbol-name(_RNvXNCNvCs21hi0yVfW1J_5impl14mains_0ARDNtB6_3Foop5AssocFG_KCRL0_hvEuNtB6_9AutoTraitEL_j3_NtB2_3Bar6method)
50-
--> $DIR/impl1.rs:64:13
50+
--> $DIR/impl1.rs:63:13
5151
|
5252
LL | #[rustc_symbol_name]
5353
| ^^^^^^^^^^^^^^^^^^^^
5454

5555
error: demangling(<[&dyn impl1[17891616a171812d]::Foo<Assoc = for<'a> extern "C" fn(&'a u8, ...)> + impl1[17891616a171812d]::AutoTrait; 3: usize] as impl1[17891616a171812d]::main::{closure#1}::Bar>::method)
56-
--> $DIR/impl1.rs:64:13
56+
--> $DIR/impl1.rs:63:13
5757
|
5858
LL | #[rustc_symbol_name]
5959
| ^^^^^^^^^^^^^^^^^^^^
6060

6161
error: demangling-alt(<[&dyn impl1::Foo<Assoc = for<'a> extern "C" fn(&'a u8, ...)> + impl1::AutoTrait; 3] as impl1::main::{closure#1}::Bar>::method)
62-
--> $DIR/impl1.rs:64:13
62+
--> $DIR/impl1.rs:63:13
6363
|
6464
LL | #[rustc_symbol_name]
6565
| ^^^^^^^^^^^^^^^^^^^^
6666

6767
error: def-path(<[&dyn Foo<Assoc = for<'r> extern "C" fn(&'r u8, ...)> + AutoTrait; 3] as main::{closure#1}::Bar>::method)
68-
--> $DIR/impl1.rs:71:13
68+
--> $DIR/impl1.rs:70:13
6969
|
7070
LL | #[rustc_def_path]
7171
| ^^^^^^^^^^^^^^^^^

0 commit comments

Comments
 (0)