Skip to content

Commit 90b95cf

Browse files
RalfJungmatklad
andauthored
fix slice comparison
Co-Authored-By: Aleksey Kladov <[email protected]>
1 parent 4e51ef7 commit 90b95cf

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/libcore/tests/ptr.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ fn test_as_mut() {
163163
// Pointers to unsized types -- slices
164164
let s: &mut [u8] = &mut [1, 2, 3];
165165
let ms: *mut [u8] = s;
166-
assert_eq!(ms.as_mut(), Some(&mut [1, 2, 3]));
166+
assert_eq!(ms.as_mut(), Some(&mut [1, 2, 3][..]));
167167

168168
let mz: *mut [u8] = &mut [];
169169
assert_eq!(mz.as_mut(), Some(&mut [][..]));

0 commit comments

Comments
 (0)