Skip to main content

CheckLibcZero

Trait CheckLibcZero 

Source
pub trait CheckLibcZero {
    // Required method
    fn check_libc_zero(self) -> Result<()>;
}
Expand description

libc convention where 0 means success and any non-zero value indicates failure (with errno set). Used by APIs like sigemptyset, sigaction, pthread_*, etc.

Required Methods§

Source

fn check_libc_zero(self) -> Result<()>

Returns Ok(()) if self == 0, otherwise the current errno as an io::Error.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl CheckLibcZero for i32

Source§

impl CheckLibcZero for i64

Source§

impl CheckLibcZero for isize

Implementors§