fn arch_from_uname(raw: &str) -> Option<Arch> {
    if let Ok(arch) = Arch::from_str(raw) {
        return Some(arch);
    };

    match raw {
        "armv7" | "armv7l" | "arm64" => Some(Arch::ARM),
        "ppc64" | "ppc64le" => Some(Arch::POWERPC64),
        _ => None,
    }
}
/// Arch::from_str only handles the exact names used
/// by the rust compiler (that's the policy of the platforms crate)
/// However, uname -m has more varied output, which we need to detect
:from_str only handles the exact names used
by the rust compiler (that's the policy of the platforms crate)
However, uname -m has more varied output, which we need to detect
: from_str only handles the exact names used by the rust compiler ( that ' s the policy of the platforms crate ) However uname - m has more varied output which we need to detect
fn arch_from_uname(raw: &str) -> Option<Arch> {
    if let Ok(arch) = Arch::from_str(raw) {
        return Some(arch);
    };
    match raw {
        "armv7" | "armv7l" | "arm64" => Some(Arch::ARM),
        "ppc64" | "ppc64le" => Some(Arch::POWERPC64),
        _ => None,
    }
}
fn arch_from_uname ( raw : & str ) -> Option < Arch > { if let Ok ( arch ) = Arch :: from_str ( raw ) { return Some ( arch ) ; } ; match raw { " " | " " | " " => Some ( Arch :: ARM ) , " " | " " => Some ( Arch :: POWERPC64 ) , _ => None , } }
Arch::from_str only handles the exact names used
by the rust compiler (that's the policy of the platforms crate)
However, uname -m has more varied output, which we need to detect
Arch :: from_str only handles the exact names used by the rust compiler ( that ' s the policy of the platforms crate ) However uname - m has more varied output which we need to detect
raw
&str
raw
&str