Skip to content

Commit 006b9b9

Browse files
1 parent eabdffd commit 006b9b9

5 files changed

Lines changed: 9 additions & 9 deletions

File tree

Source/Library.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,4 @@ pub mod Scheduler;
1212
pub mod Task;
1313

1414
// --- Internal Implementation ---
15-
mod Queue;
15+
pub mod Queue;

Source/Queue/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
#![allow(non_snake_case, non_camel_case_types)]
88

9-
mod StealingQueue;
9+
pub mod StealingQueue;
1010

1111
// Re-exports the `StealingQueue` for use within the `Echo` crate, but keeps it
1212
// private from external consumers.

Source/Scheduler/SchedulerBuilder.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ impl SchedulerBuilder {
3333
/// By default, the worker count is set to the number of logical CPUs on the
3434
/// system, with a minimum of 2.
3535
pub fn New() -> Self {
36-
let DefaultWorkerCount = num_cpus::get().max(2);
36+
let DefaultWorkerCount = num_cpus::get().max(2).expect("");
3737
Self { WorkerCount:DefaultWorkerCount, QueueConfiguration:HashMap::new() }
3838
}
3939

@@ -45,7 +45,7 @@ impl SchedulerBuilder {
4545
pub fn WithWorkerCount(mut self, WorkerCount:usize) -> Self {
4646
if WorkerCount == 0 {
4747
warn!("[SchedulerBuilder] Worker count of 0 is invalid. Defaulting to number of logical CPUs.");
48-
self.WorkerCount = num_cpus::get().max(2);
48+
self.WorkerCount = num_cpus::get().max(2).expect("");
4949
} else {
5050
self.WorkerCount = WorkerCount;
5151
}

Source/Scheduler/Worker.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ use tokio::time::{Duration, sleep};
1010
/// @description Defines the `Worker` struct, which represents a single
1111
/// execution thread in the scheduler's pool. This is an internal component of
1212
/// the scheduler.
13-
use crate::queue::StealingQueue;
13+
use crate::Queue::StealingQueue;
1414

1515
/// Represents a single worker thread that continuously polls the work-stealing
1616
/// queue for tasks to execute.

Source/Task/mod.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,15 @@
66
#![allow(non_snake_case, non_camel_case_types)]
77

88
// --- Sub-modules ---
9-
mod Priority;
10-
mod Task;
9+
pub mod Priority;
10+
pub mod Task;
1111

1212
// --- Public Re-exports ---
1313

1414
// The enum representing the priority of a task.
1515
// @see Priority
1616
//
17-
pub use self::Priority::Priority;
17+
// pub use self::Priority::Priority;
1818
// The struct representing a single unit of work for the scheduler.
1919
// @see Task
20-
pub use self::Task::Task;
20+
// pub use self::Task::Task;

0 commit comments

Comments
 (0)