From 7936ecff4803e30ec0d3d85a531860025bb6b346 Mon Sep 17 00:00:00 2001 From: woppopo Date: Mon, 18 Oct 2021 19:19:28 +0900 Subject: Make more `From` impls `const` --- library/core/src/array/mod.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'library/core/src/array') diff --git a/library/core/src/array/mod.rs b/library/core/src/array/mod.rs index 8d5c0510404..b27c36baf37 100644 --- a/library/core/src/array/mod.rs +++ b/library/core/src/array/mod.rs @@ -125,7 +125,8 @@ impl TryFromSliceError { } #[stable(feature = "try_from_slice_error", since = "1.36.0")] -impl From for TryFromSliceError { +#[rustc_const_unstable(feature = "const_convert", issue = "88674")] +impl const From for TryFromSliceError { fn from(x: Infallible) -> TryFromSliceError { match x {} } -- cgit 1.4.1-3-g733a5