MCPcopy Create free account
hub / github.com/bytecodealliance/wasmtime / try_from

Method try_from

cranelift/codegen/src/ir/constant.rs:66–70  ·  view source on GitHub ↗
(value: &ConstantData)

Source from the content-addressed store, hash-verified

64 type Error = <[u8; 16] as TryFrom<&'static [u8]>>::Error;
65
66 fn try_from(value: &ConstantData) -> Result<Self, Self::Error> {
67 Ok(Ieee128::with_bits(u128::from_le_bytes(
68 value.as_slice().try_into()?,
69 )))
70 }
71}
72
73impl ConstantData {

Callers

nothing calls this directly

Calls 3

OkFunction · 0.85
try_intoMethod · 0.45
as_sliceMethod · 0.45

Tested by

no test coverage detected