Skip to content

Commit

Permalink
src/riot-rs-threads: export thread flags as flags::
Browse files Browse the repository at this point in the history
  • Loading branch information
kaspar030 committed Oct 17, 2023
1 parent e702d93 commit 6f800fa
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 4 deletions.
5 changes: 4 additions & 1 deletion src/riot-rs-core/src/c/thread.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
use core::ffi::{c_char, c_int, c_void};
use core::unimplemented;

pub use crate::thread::{RunqueueId, Thread, ThreadFlags, ThreadId, ThreadState, WaitMode};
pub use crate::thread::{
flags::{ThreadFlags, WaitMode},
RunqueueId, Thread, ThreadId, ThreadState,
};
pub use ref_cast::RefCast;

use riot_rs_threads::current_pid;
Expand Down
2 changes: 1 addition & 1 deletion src/riot-rs-core/src/c/thread_flags.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
pub use super::thread::thread_t;
use super::thread::thread_t2id;
pub use crate::thread::{thread_flags, ThreadFlags};
pub use crate::thread::{thread_flags, thread_flags::ThreadFlags};

pub const THREAD_FLAG_MSG_WAITING: ThreadFlags = 1 << 15;
pub const THREAD_FLAG_TIMEOUT: ThreadFlags = 1 << 14;
Expand Down
2 changes: 1 addition & 1 deletion src/riot-rs-threads/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ pub mod thread_flags;

pub use arch::schedule;
pub use thread::{Thread, ThreadState};
pub use thread_flags::*;
pub use thread_flags as flags;
pub use threadlist::ThreadList;

use ensure_once::EnsureOnce;
Expand Down
2 changes: 1 addition & 1 deletion src/riot-rs-threads/src/thread.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
pub use crate::{RunqueueId, ThreadFlags, ThreadId};
pub use crate::{thread_flags::ThreadFlags, RunqueueId, ThreadId};

/// Main struct for holding thread data
#[derive(Debug)]
Expand Down

0 comments on commit 6f800fa

Please sign in to comment.