Struct rust_version::Version
[−]
[src]
pub struct Version { /* fields omitted */ }
Rust version.
Methods
impl Version
[src]
fn from_installed(toolchain: Option<&str>) -> Result<Version>
[src]
Parses the version from a currently installed rustc
toolchain.
fn from_manifest(name: &str) -> Result<Version>
[src]
Parses the version from a manifest at static.rust-lang.org.
fn latest_stable() -> Result<Version>
[src]
Parses the version from the latest Stable.
fn latest_beta() -> Result<Version>
[src]
Parses the version from the latest Stable.
fn latest_nightly() -> Result<Version>
[src]
Parses the version from the latest Stable.
fn rustup_install(&self) -> Result<()>
[src]
Installs this version via rustup.
fn release(&self) -> Release
[src]
The release for this version.
fn channel(&self) -> Channel
[src]
The channel for this version.
fn date(&self) -> Option<Date>
[src]
The date for this version.
fn commit(&self) -> Option<&Commit>
[src]
The commit for this version.
fn toolchain(&self) -> &str
[src]
The name of the toolchain required by rustup and co.
This doesn't include the target.
Trait Implementations
impl Debug for Version
[src]
impl Clone for Version
[src]
fn clone(&self) -> Version
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl<'a> TryFrom<&'a [u8]> for Version
[src]
type Error = ParseVersionError<'a>
🔬 This is a nightly-only experimental API. (
try_from
)The type returned in the event of a conversion error.
fn try_from(bytes: &'a [u8]) -> Result<Version, ParseVersionError<'a>>
[src]
🔬 This is a nightly-only experimental API. (
try_from
)Performs the conversion.
impl<'a> TryFrom<&'a str> for Version
[src]
type Error = ParseVersionError<'a>
🔬 This is a nightly-only experimental API. (
try_from
)The type returned in the event of a conversion error.
fn try_from(s: &'a str) -> Result<Version, ParseVersionError<'a>>
[src]
🔬 This is a nightly-only experimental API. (
try_from
)Performs the conversion.