devela::all

Function array_from_ref

1.53.0 (const: 1.63.0) · Source
pub const fn array_from_ref<T>(s: &T) -> &[T; 1]
Expand description

core Converts a reference to T into &[T; 1] (without copying).

Re-exported from core::array:: from_refarray_from_ref.


Converts a reference to T into a reference to an array of length 1 (without copying).