diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-17 12:19:43 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-17 12:19:43 +0000 |
commit | 3e3e70d529d8c7d7c4d7bc4fefc9f109393b9245 (patch) | |
tree | daf049b282ab10e8c3d03e409b3cd84ff3f7690c /tests/ui/unsized | |
parent | Adding debian version 1.68.2+dfsg1-1. (diff) | |
download | rustc-3e3e70d529d8c7d7c4d7bc4fefc9f109393b9245.tar.xz rustc-3e3e70d529d8c7d7c4d7bc4fefc9f109393b9245.zip |
Merging upstream version 1.69.0+dfsg1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tests/ui/unsized')
-rw-r--r-- | tests/ui/unsized/box-instead-of-dyn-fn.stderr | 2 | ||||
-rw-r--r-- | tests/ui/unsized/issue-71659.stderr | 2 | ||||
-rw-r--r-- | tests/ui/unsized/param-mentioned-by-different-field.stderr | 2 | ||||
-rw-r--r-- | tests/ui/unsized/unsized3-rpass.rs | 4 |
4 files changed, 5 insertions, 5 deletions
diff --git a/tests/ui/unsized/box-instead-of-dyn-fn.stderr b/tests/ui/unsized/box-instead-of-dyn-fn.stderr index c96c59afc..bfb7c3957 100644 --- a/tests/ui/unsized/box-instead-of-dyn-fn.stderr +++ b/tests/ui/unsized/box-instead-of-dyn-fn.stderr @@ -9,7 +9,7 @@ LL | | move || println!("{a}") | | expected because of this LL | | } else { LL | | Box::new(move || println!("{}", b)) - | | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected closure, found struct `Box` + | | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected closure, found `Box<[closure@box-instead-of-dyn-fn.rs:10:18]>` LL | | LL | | } | |_____- `if` and `else` have incompatible types diff --git a/tests/ui/unsized/issue-71659.stderr b/tests/ui/unsized/issue-71659.stderr index d7b95f557..b57b3015e 100644 --- a/tests/ui/unsized/issue-71659.stderr +++ b/tests/ui/unsized/issue-71659.stderr @@ -8,7 +8,7 @@ note: required by a bound in `Cast::cast` --> $DIR/issue-71659.rs:19:15 | LL | fn cast<T: ?Sized>(&self) -> &T - | ---- required by a bound in this + | ---- required by a bound in this associated function LL | where LL | Self: CastTo<T>, | ^^^^^^^^^ required by this bound in `Cast::cast` diff --git a/tests/ui/unsized/param-mentioned-by-different-field.stderr b/tests/ui/unsized/param-mentioned-by-different-field.stderr index d18fa6456..b1ad0cb5b 100644 --- a/tests/ui/unsized/param-mentioned-by-different-field.stderr +++ b/tests/ui/unsized/param-mentioned-by-different-field.stderr @@ -2,7 +2,7 @@ error[E0308]: mismatched types --> $DIR/param-mentioned-by-different-field.rs:8:25 | LL | let y: &Foo<[u8]> = &x; - | ---------- ^^ expected slice `[u8]`, found array `[u8; 1]` + | ---------- ^^ expected `&Foo<[u8]>`, found `&Foo<[u8; 1]>` | | | expected due to this | diff --git a/tests/ui/unsized/unsized3-rpass.rs b/tests/ui/unsized/unsized3-rpass.rs index 4d5e89575..a3f92be6c 100644 --- a/tests/ui/unsized/unsized3-rpass.rs +++ b/tests/ui/unsized/unsized3-rpass.rs @@ -59,7 +59,7 @@ pub fn main() { } let data: Box<Foo_<i32>> = Box::new(Foo_ { f: [1, 2, 3] }); - let x: &Foo<i32> = mem::transmute(slice::from_raw_parts(&*data, 3)); + let x: &Foo<i32> = mem::transmute(ptr::slice_from_raw_parts(&*data, 3)); assert_eq!(x.f.len(), 3); assert_eq!(x.f[0], 1); @@ -70,7 +70,7 @@ pub fn main() { let data: Box<_> = Box::new(Baz_ { f1: 42, f2: ['a' as u8, 'b' as u8, 'c' as u8, 'd' as u8, 'e' as u8] }); - let x: &Baz = mem::transmute(slice::from_raw_parts(&*data, 5)); + let x: &Baz = mem::transmute(ptr::slice_from_raw_parts(&*data, 5)); assert_eq!(x.f1, 42); let chs: Vec<char> = x.f2.chars().collect(); assert_eq!(chs.len(), 5); |