rutabaga_gfx/rutabaga_os/sys/stub/
descriptor.rsuse std::fs::File;
use crate::rutabaga_os::descriptor::AsRawDescriptor;
use crate::rutabaga_os::descriptor::FromRawDescriptor;
use crate::rutabaga_os::descriptor::IntoRawDescriptor;
use crate::rutabaga_os::descriptor::SafeDescriptor;
type Error = std::io::Error;
type Result<T> = std::result::Result<T, Error>;
pub type RawDescriptor = i64;
impl Drop for SafeDescriptor {
fn drop(&mut self) {
unimplemented!()
}
}
impl SafeDescriptor {
pub fn try_clone(&self) -> Result<SafeDescriptor> {
Err(Error::last_os_error())
}
}
impl From<SafeDescriptor> for File {
fn from(_s: SafeDescriptor) -> File {
unimplemented!()
}
}
macro_rules! AsRawDescriptor {
($name:ident) => {
impl AsRawDescriptor for $name {
fn as_raw_descriptor(&self) -> RawDescriptor {
unimplemented!()
}
}
};
}
macro_rules! FromRawDescriptor {
($name:ident) => {
impl FromRawDescriptor for $name {
unsafe fn from_raw_descriptor(_descriptor: RawDescriptor) -> Self {
unimplemented!()
}
}
};
}
macro_rules! IntoRawDescriptor {
($name:ident) => {
impl IntoRawDescriptor for $name {
fn into_raw_descriptor(self) -> RawDescriptor {
unimplemented!()
}
}
};
}
AsRawDescriptor!(File);
FromRawDescriptor!(File);
IntoRawDescriptor!(File);