// Copyright 2018-2024 the Deno authors. All rights reserved. MIT license. use std::convert::Infallible; pub trait InfallibleResultExt { fn unwrap_infallible(self) -> T; } impl InfallibleResultExt for Result { fn unwrap_infallible(self) -> T { match self { Ok(value) => value, Err(never) => match never {}, } } }