]> git.lizzy.rs Git - rust.git/commitdiff
Fmt and test revert
authorJack Huey <jack.huey@umassmed.edu>
Fri, 12 Mar 2021 02:49:41 +0000 (21:49 -0500)
committerJack Huey <jack.huey@umassmed.edu>
Wed, 31 Mar 2021 14:16:37 +0000 (10:16 -0400)
compiler/rustc_middle/src/ty/fold.rs
src/test/ui/symbol-names/impl1.legacy.stderr
src/test/ui/symbol-names/impl1.rs
src/test/ui/symbol-names/impl1.v0.stderr

index 819399141b9e65b9a3dd86137072a2a272cf2214..70f3ac3004042708a5d548bbf1187ca4773f7b91 100644 (file)
@@ -879,14 +879,14 @@ fn visit_ty(&mut self, t: Ty<'tcx>) -> ControlFlow<Self::BreakTy> {
                         if kind != bound_ty.kind {
                             bug!(
                                 "Mismatched type kinds: {:?} doesn't var in list {:?}",
-                                bound_ty.kind, list_var
+                                bound_ty.kind,
+                                list_var
                             );
                         }
                     }
-                    _ => bug!(
-                        "Mismatched bound variable kinds! Expected type, found {:?}",
-                        list_var
-                    ),
+                    _ => {
+                        bug!("Mismatched bound variable kinds! Expected type, found {:?}", list_var)
+                    }
                 }
             }
 
@@ -908,7 +908,9 @@ fn visit_region(&mut self, r: ty::Region<'tcx>) -> ControlFlow<Self::BreakTy> {
                         if kind != br.kind {
                             bug!(
                                 "Mismatched region kinds: {:?} doesn't match var ({:?}) in list ({:?})",
-                                br.kind, list_var, self.bound_vars
+                                br.kind,
+                                list_var,
+                                self.bound_vars
                             );
                         }
                     }
index c9c2664e6de9b41124ead30e8e5195691650e4dc..bd32a39a65cb06a50a179b74630dc1bc76253443 100644 (file)
@@ -1,71 +1,71 @@
-error: symbol-name(_ZN5impl13foo3Foo3bar17h2e76f87b171019e0E)
-  --> $DIR/impl1.rs:16:9
+error: symbol-name(_ZN5impl13foo3Foo3bar17<SYMBOL_HASH>)
+  --> $DIR/impl1.rs:15:9
    |
 LL |         #[rustc_symbol_name]
    |         ^^^^^^^^^^^^^^^^^^^^
 
-error: demangling(impl1::foo::Foo::bar::h2e76f87b171019e0)
-  --> $DIR/impl1.rs:16:9
+error: demangling(impl1::foo::Foo::bar::<SYMBOL_HASH>)
+  --> $DIR/impl1.rs:15:9
    |
 LL |         #[rustc_symbol_name]
    |         ^^^^^^^^^^^^^^^^^^^^
 
 error: demangling-alt(impl1::foo::Foo::bar)
-  --> $DIR/impl1.rs:16:9
+  --> $DIR/impl1.rs:15:9
    |
 LL |         #[rustc_symbol_name]
    |         ^^^^^^^^^^^^^^^^^^^^
 
 error: def-path(foo::Foo::bar)
-  --> $DIR/impl1.rs:23:9
+  --> $DIR/impl1.rs:22:9
    |
 LL |         #[rustc_def_path]
    |         ^^^^^^^^^^^^^^^^^
 
-error: symbol-name(_ZN5impl13bar33_$LT$impl$u20$impl1..foo..Foo$GT$3baz17hb388a171ee84bca1E)
-  --> $DIR/impl1.rs:34:9
+error: symbol-name(_ZN5impl13bar33_$LT$impl$u20$impl1..foo..Foo$GT$3baz17<SYMBOL_HASH>)
+  --> $DIR/impl1.rs:33:9
    |
 LL |         #[rustc_symbol_name]
    |         ^^^^^^^^^^^^^^^^^^^^
 
-error: demangling(impl1::bar::<impl impl1::foo::Foo>::baz::hb388a171ee84bca1)
-  --> $DIR/impl1.rs:34:9
+error: demangling(impl1::bar::<impl impl1::foo::Foo>::baz::<SYMBOL_HASH>)
+  --> $DIR/impl1.rs:33:9
    |
 LL |         #[rustc_symbol_name]
    |         ^^^^^^^^^^^^^^^^^^^^
 
 error: demangling-alt(impl1::bar::<impl impl1::foo::Foo>::baz)
-  --> $DIR/impl1.rs:34:9
+  --> $DIR/impl1.rs:33:9
    |
 LL |         #[rustc_symbol_name]
    |         ^^^^^^^^^^^^^^^^^^^^
 
 error: def-path(bar::<impl foo::Foo>::baz)
-  --> $DIR/impl1.rs:41:9
+  --> $DIR/impl1.rs:40:9
    |
 LL |         #[rustc_def_path]
    |         ^^^^^^^^^^^^^^^^^
 
-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)
-  --> $DIR/impl1.rs:64:13
+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>)
+  --> $DIR/impl1.rs:63:13
    |
 LL |             #[rustc_symbol_name]
    |             ^^^^^^^^^^^^^^^^^^^^
 
-error: demangling(<[&dyn impl1::Foo+Assoc = extern "C" fn(&u8, ::.)+impl1::AutoTrait; 3] as impl1::main::{{closure}}::Bar>::method::SYMBOL_HASH)
-  --> $DIR/impl1.rs:64:13
+error: demangling(<[&dyn impl1::Foo+Assoc = extern "C" fn(&u8, ::.)+impl1::AutoTrait; 3] as impl1::main::{{closure}}::Bar>::method::<SYMBOL_HASH>)
+  --> $DIR/impl1.rs:63:13
    |
 LL |             #[rustc_symbol_name]
    |             ^^^^^^^^^^^^^^^^^^^^
 
 error: demangling-alt(<[&dyn impl1::Foo+Assoc = extern "C" fn(&u8, ::.)+impl1::AutoTrait; 3] as impl1::main::{{closure}}::Bar>::method)
-  --> $DIR/impl1.rs:64:13
+  --> $DIR/impl1.rs:63:13
    |
 LL |             #[rustc_symbol_name]
    |             ^^^^^^^^^^^^^^^^^^^^
 
 error: def-path(<[&dyn Foo<Assoc = for<'r> extern "C" fn(&'r u8, ...)> + AutoTrait; 3] as main::{closure#1}::Bar>::method)
-  --> $DIR/impl1.rs:71:13
+  --> $DIR/impl1.rs:70:13
    |
 LL |             #[rustc_def_path]
    |             ^^^^^^^^^^^^^^^^^
index 0a865a602f64b2aa90cf3252c00cfce74923f303..771695330d8bd92851a289e95b4618ae91f147aa 100644 (file)
@@ -3,8 +3,7 @@
 // revisions: legacy v0
 //[legacy]compile-flags: -Z symbol-mangling-version=legacy
     //[v0]compile-flags: -Z symbol-mangling-version=v0
-//[legacy]normalize-stderr-test: "method17h[\d\w]+" -> "method17SYMBOL_HASH"
-//[legacy]normalize-stderr-test: "method::h[\d\w]+" -> "method::SYMBOL_HASH"
+//[legacy]normalize-stderr-test: "h[\w]{16}E?\)" -> "<SYMBOL_HASH>)"
 
 #![feature(auto_traits, rustc_attrs)]
 #![allow(dead_code)]
index a68a74c8552539a18a84d49f944b3b0e12493532..3a6610935d6e3dcc8fa303912df4e09c8fab9bd5 100644 (file)
@@ -1,71 +1,71 @@
 error: symbol-name(_RNvMNtCs21hi0yVfW1J_5impl13fooNtB2_3Foo3bar)
-  --> $DIR/impl1.rs:16:9
+  --> $DIR/impl1.rs:15:9
    |
 LL |         #[rustc_symbol_name]
    |         ^^^^^^^^^^^^^^^^^^^^
 
 error: demangling(<impl1[17891616a171812d]::foo::Foo>::bar)
-  --> $DIR/impl1.rs:16:9
+  --> $DIR/impl1.rs:15:9
    |
 LL |         #[rustc_symbol_name]
    |         ^^^^^^^^^^^^^^^^^^^^
 
 error: demangling-alt(<impl1::foo::Foo>::bar)
-  --> $DIR/impl1.rs:16:9
+  --> $DIR/impl1.rs:15:9
    |
 LL |         #[rustc_symbol_name]
    |         ^^^^^^^^^^^^^^^^^^^^
 
 error: def-path(foo::Foo::bar)
-  --> $DIR/impl1.rs:23:9
+  --> $DIR/impl1.rs:22:9
    |
 LL |         #[rustc_def_path]
    |         ^^^^^^^^^^^^^^^^^
 
 error: symbol-name(_RNvMNtCs21hi0yVfW1J_5impl13barNtNtB4_3foo3Foo3baz)
-  --> $DIR/impl1.rs:34:9
+  --> $DIR/impl1.rs:33:9
    |
 LL |         #[rustc_symbol_name]
    |         ^^^^^^^^^^^^^^^^^^^^
 
 error: demangling(<impl1[17891616a171812d]::foo::Foo>::baz)
-  --> $DIR/impl1.rs:34:9
+  --> $DIR/impl1.rs:33:9
    |
 LL |         #[rustc_symbol_name]
    |         ^^^^^^^^^^^^^^^^^^^^
 
 error: demangling-alt(<impl1::foo::Foo>::baz)
-  --> $DIR/impl1.rs:34:9
+  --> $DIR/impl1.rs:33:9
    |
 LL |         #[rustc_symbol_name]
    |         ^^^^^^^^^^^^^^^^^^^^
 
 error: def-path(bar::<impl foo::Foo>::baz)
-  --> $DIR/impl1.rs:41:9
+  --> $DIR/impl1.rs:40:9
    |
 LL |         #[rustc_def_path]
    |         ^^^^^^^^^^^^^^^^^
 
 error: symbol-name(_RNvXNCNvCs21hi0yVfW1J_5impl14mains_0ARDNtB6_3Foop5AssocFG_KCRL0_hvEuNtB6_9AutoTraitEL_j3_NtB2_3Bar6method)
-  --> $DIR/impl1.rs:64:13
+  --> $DIR/impl1.rs:63:13
    |
 LL |             #[rustc_symbol_name]
    |             ^^^^^^^^^^^^^^^^^^^^
 
 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)
-  --> $DIR/impl1.rs:64:13
+  --> $DIR/impl1.rs:63:13
    |
 LL |             #[rustc_symbol_name]
    |             ^^^^^^^^^^^^^^^^^^^^
 
 error: demangling-alt(<[&dyn impl1::Foo<Assoc = for<'a> extern "C" fn(&'a u8, ...)> + impl1::AutoTrait; 3] as impl1::main::{closure#1}::Bar>::method)
-  --> $DIR/impl1.rs:64:13
+  --> $DIR/impl1.rs:63:13
    |
 LL |             #[rustc_symbol_name]
    |             ^^^^^^^^^^^^^^^^^^^^
 
 error: def-path(<[&dyn Foo<Assoc = for<'r> extern "C" fn(&'r u8, ...)> + AutoTrait; 3] as main::{closure#1}::Bar>::method)
-  --> $DIR/impl1.rs:71:13
+  --> $DIR/impl1.rs:70:13
    |
 LL |             #[rustc_def_path]
    |             ^^^^^^^^^^^^^^^^^