]> git.proxmox.com Git - rustc.git/blobdiff - src/test/ui/regions/region-lifetime-bounds-on-fns-where-clause.nll.stderr
New upstream version 1.56.0~beta.4+dfsg1
[rustc.git] / src / test / ui / regions / region-lifetime-bounds-on-fns-where-clause.nll.stderr
index 4ddea2c27b2a634263b583da8368661d2d09a78b..a64ad46ef462b0b12f9f0eba1bd7869e0974ce77 100644 (file)
@@ -27,17 +27,24 @@ LL |     a(x, y);
    = note: mutable references are invariant over their type parameter
    = help: see <https://doc.rust-lang.org/nomicon/subtyping.html> for more information about variance
 
-error: higher-ranked subtype error
+error[E0308]: mismatched types
   --> $DIR/region-lifetime-bounds-on-fns-where-clause.rs:20:12
    |
 LL |     let _: fn(&mut &isize, &mut &isize) = a;
-   |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ one type is more general than the other
+   |
+   = note: expected fn pointer `for<'r, 's, 't0, 't1> fn(&'r mut &'s isize, &'t0 mut &'t1 isize)`
+              found fn pointer `for<'r, 's> fn(&'r mut &isize, &'s mut &isize)`
 
-error: higher-ranked subtype error
+error[E0308]: mismatched types
   --> $DIR/region-lifetime-bounds-on-fns-where-clause.rs:20:12
    |
 LL |     let _: fn(&mut &isize, &mut &isize) = a;
-   |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ one type is more general than the other
+   |
+   = note: expected fn pointer `for<'r, 's, 't0, 't1> fn(&'r mut &'s isize, &'t0 mut &'t1 isize)`
+              found fn pointer `for<'r, 's> fn(&'r mut &isize, &'s mut &isize)`
 
 error: aborting due to 4 previous errors
 
+For more information about this error, try `rustc --explain E0308`.