#[non_exhaustive]pub enum FdError {
InvalidValue(i32),
TooLarge(i32),
}Available on crate feature
sys only.Expand description
Error type for FD parsing.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
InvalidValue(i32)
Invalid FD value (must be non-negative)
File descriptors must be non-negative integers. This variant contains the invalid value.
TooLarge(i32)
FD too large (platform-dependent)
The provided file descriptor exceeds the maximum valid value for the platform.
On Linux, the maximum is typically 2^20-1 (1,048,576).
On other platforms, it may be i32::MAX.
This variant contains the invalid value.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for FdError
impl<'de> Deserialize<'de> for FdError
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Error for FdError
Available on crate feature std only.
impl Error for FdError
Available on crate feature
std only.1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
impl Copy for FdError
impl Eq for FdError
impl StructuralPartialEq for FdError
Auto Trait Implementations§
impl Freeze for FdError
impl RefUnwindSafe for FdError
impl Send for FdError
impl Sync for FdError
impl Unpin for FdError
impl UnwindSafe for FdError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more