fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
        let platform = match s {
            "x86_64-apple-darwin" => Self::X86_64AppleDarwin,
            "x86_64-unknown-linux-musl" => Self::X86_64UnknownLinuxMusl,
            "x86_64-unknown-linux-gnu" => Self::X86_64UnknownLinuxMusl,
            other => Self(Cow::Owned(other.to_owned())),
        };
        Ok(platform)
    }
/// When parsing from a string, here is the chance to make any
/// edits or to collapse multiple target names into one. An
/// example of this is how we transform the target name
/// `x86_64-unknown-linux-gnu` into `x86_64-unknown-linux-musl`.
///
/// Additionally, if there are any "target strings" that we
/// know for a fact that we cannot support, we can identify
/// those strings here and manually reject them in order to
/// prevent downstream tooling from incorrectly allowing those
/// targets.
///
/// All other target names should pass through unchanged.
When parsing from a string, here is the chance to make any
edits or to collapse multiple target names into one.

Additionally, if there are any "target strings" that we
know for a fact that we cannot support, we can identify
those strings here and manually reject them in order to
prevent downstream tooling from incorrectly allowing those
targets.

All other target names should pass through unchanged.
When parsing from a string here is the chance to make any edits or to collapse multiple target names into one . Additionally if there are any " target strings " that we know for a fact that we cannot support we can identify those strings here and manually reject them in order to prevent downstream tooling from incorrectly allowing those targets . All other target names should pass through unchanged .
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
        let platform = match s {
            "x86_64-apple-darwin" => Self::X86_64AppleDarwin,
            "x86_64-unknown-linux-musl" => Self::X86_64UnknownLinuxMusl,
            "x86_64-unknown-linux-gnu" => Self::X86_64UnknownLinuxMusl,
            other => Self(Cow::Owned(other.to_owned())),
        };
        Ok(platform)
    }
fn from_str ( s : & str ) -> std :: result :: Result < Self , Self :: Err > { let platform = match s { " " => Self :: X86_64AppleDarwin , " " => Self :: X86_64UnknownLinuxMusl , " " => Self :: X86_64UnknownLinuxMusl , other => Self ( Cow :: Owned ( other . to_owned ( ) ) ) , } ; Ok ( platform ) }
When parsing from a string, here is the chance to make any
edits or to collapse multiple target names into one.
When parsing from a string here is the chance to make any edits or to collapse multiple target names into one .
s
&str
s
&str