diff options
| author | bors <bors@rust-lang.org> | 2020-08-12 15:11:25 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2020-08-12 15:11:25 +0000 |
| commit | 3ed0a4ce5dd199c2abb1241fd59a5bdfb3bc5ee8 (patch) | |
| tree | aa892fc0cc34cda712b271eb566ed73e27a7ba71 | |
| parent | 3337f7956cf6100c9e5acfd72d42ec312efb6a7f (diff) | |
| parent | 318c74af2b99654c9c185c7e5ecf1486f64eb0e8 (diff) | |
| download | rust-3ed0a4ce5dd199c2abb1241fd59a5bdfb3bc5ee8.tar.gz rust-3ed0a4ce5dd199c2abb1241fd59a5bdfb3bc5ee8.zip | |
Auto merge of #5898 - flip1995:rustup, r=flip1995
Rustup r? @ghost changelog: none
| -rw-r--r-- | clippy_lints/src/consts.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/clippy_lints/src/consts.rs b/clippy_lints/src/consts.rs index 49ff86a205d..c77b80bc237 100644 --- a/clippy_lints/src/consts.rs +++ b/clippy_lints/src/consts.rs @@ -517,7 +517,7 @@ pub fn miri_to_const(result: &ty::Const<'_>) -> Option<Constant> { ty::ConstKind::Value(ConstValue::Slice { data, start, end }) => match result.ty.kind { ty::Ref(_, tam, _) => match tam.kind { ty::Str => String::from_utf8( - data.inspect_with_undef_and_ptr_outside_interpreter(start..end) + data.inspect_with_uninit_and_ptr_outside_interpreter(start..end) .to_owned(), ) .ok() @@ -530,7 +530,7 @@ pub fn miri_to_const(result: &ty::Const<'_>) -> Option<Constant> { ty::Array(sub_type, len) => match sub_type.kind { ty::Float(FloatTy::F32) => match miri_to_const(len) { Some(Constant::Int(len)) => alloc - .inspect_with_undef_and_ptr_outside_interpreter(0..(4 * len as usize)) + .inspect_with_uninit_and_ptr_outside_interpreter(0..(4 * len as usize)) .to_owned() .chunks(4) .map(|chunk| { @@ -544,7 +544,7 @@ pub fn miri_to_const(result: &ty::Const<'_>) -> Option<Constant> { }, ty::Float(FloatTy::F64) => match miri_to_const(len) { Some(Constant::Int(len)) => alloc - .inspect_with_undef_and_ptr_outside_interpreter(0..(8 * len as usize)) + .inspect_with_uninit_and_ptr_outside_interpreter(0..(8 * len as usize)) .to_owned() .chunks(8) .map(|chunk| { |
