Skip to content

Commit 7f5746f

Browse files
committed
core::rt: Rename Sched.task_queue to work_queue
1 parent 56c0b18 commit 7f5746f

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/libcore/rt/sched.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ pub mod local_sched;
3131
/// thread local storage and the running task is owned by the
3232
/// scheduler.
3333
pub struct Scheduler {
34-
priv task_queue: WorkQueue<~Task>,
34+
priv work_queue: WorkQueue<~Task>,
3535
stack_pool: StackPool,
3636
/// The event loop used to drive the scheduler and perform I/O
3737
event_loop: ~EventLoopObject,
@@ -76,7 +76,7 @@ pub impl Scheduler {
7676

7777
Scheduler {
7878
event_loop: event_loop,
79-
task_queue: WorkQueue::new(),
79+
work_queue: WorkQueue::new(),
8080
stack_pool: StackPool::new(),
8181
saved_context: Context::empty(),
8282
current_task: None,
@@ -106,7 +106,7 @@ pub impl Scheduler {
106106
}
107107

108108
let sched = local_sched::take();
109-
assert!(sched.task_queue.is_empty());
109+
assert!(sched.work_queue.is_empty());
110110
return sched;
111111
}
112112

@@ -116,7 +116,7 @@ pub impl Scheduler {
116116
/// to run it later. Always use this instead of pushing to the work queue
117117
/// directly.
118118
fn enqueue_task(&mut self, task: ~Task) {
119-
self.task_queue.push_front(task);
119+
self.work_queue.push_front(task);
120120
self.event_loop.callback(resume_task_from_queue);
121121

122122
fn resume_task_from_queue() {
@@ -133,7 +133,7 @@ pub impl Scheduler {
133133
rtdebug!("looking in work queue for task to schedule");
134134

135135
let mut this = self;
136-
match this.task_queue.pop_front() {
136+
match this.work_queue.pop_front() {
137137
Some(task) => {
138138
rtdebug!("resuming task from work queue");
139139
this.resume_task_immediately(task);

0 commit comments

Comments
 (0)