Move pthread::Errno to separate module.

This commit is contained in:
4lDO2
2024-09-07 12:46:16 +02:00
parent e73b891e77
commit 4bd0d2a1ef
21 changed files with 77 additions and 80 deletions
+2 -2
View File
@@ -1,8 +1,8 @@
// Used design from https://www.remlab.net/op/futex-condvar.shtml
use crate::{
error::Errno,
header::{pthread::*, time::timespec},
pthread::Errno,
};
use core::sync::atomic::{AtomicU32 as AtomicUint, Ordering};
@@ -12,7 +12,7 @@ pub struct Cond {
prev: AtomicUint,
}
type Result<T, E = crate::pthread::Errno> = core::result::Result<T, E>;
type Result<T, E = Errno> = core::result::Result<T, E>;
impl Cond {
pub fn new() -> Self {
+1 -1
View File
@@ -19,12 +19,12 @@ pub use self::{
};
use crate::{
error::Errno,
header::{
errno::{EAGAIN, ETIMEDOUT},
time::timespec,
},
platform::{types::*, Pal, Sys},
pthread::Errno,
};
use core::{
mem::MaybeUninit,
+1
View File
@@ -4,6 +4,7 @@ use core::{
};
use crate::{
error::Errno,
header::{errno::*, pthread::*, time::timespec},
pthread::*,
};