Added docs for From<c_int> for ExitStatus

This commit is contained in:
Vincent Esche 2020-07-13 13:47:18 +02:00
parent 9d09331e00
commit 538f15776b
4 changed files with 4 additions and 0 deletions

View File

@ -246,6 +246,7 @@ impl ExitStatus {
}
}
/// Converts a raw `c_int` to a type-safe `ExitStatus` by wrapping it without copying.
impl From<c_int> for ExitStatus {
fn from(a: c_int) -> ExitStatus {
ExitStatus(a as i64)

View File

@ -481,6 +481,7 @@ impl ExitStatus {
}
}
/// Converts a raw `c_int` to a type-safe `ExitStatus` by wrapping it without copying.
impl From<c_int> for ExitStatus {
fn from(a: c_int) -> ExitStatus {
ExitStatus(a)

View File

@ -376,6 +376,7 @@ impl ExitStatus {
}
}
/// Converts a raw `c_int` to a type-safe `ExitStatus` by wrapping it without copying.
impl From<c_int> for ExitStatus {
fn from(a: c_int) -> ExitStatus {
ExitStatus(a)

View File

@ -378,6 +378,7 @@ impl ExitStatus {
}
}
/// Converts a raw `c::DWORD` to a type-safe `ExitStatus` by wrapping it without copying.
impl From<c::DWORD> for ExitStatus {
fn from(u: c::DWORD) -> ExitStatus {
ExitStatus(u)