aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorEmil Fresk <emil.fresk@gmail.com>2021-01-10 15:47:25 +0100
committerEmil Fresk <emil.fresk@gmail.com>2021-01-10 15:47:25 +0100
commit0658d53843d5452085e7458269e0abebbf431971 (patch)
tree1ded67c4de9d6182b6ee7ba29787562d90791f9c /src
parentaaa92ea2fac23d2679b5efc1178a45d994762bca (diff)
cleanup
Diffstat (limited to 'src')
-rw-r--r--src/tq.rs9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/tq.rs b/src/tq.rs
index be854a5..4c89a66 100644
--- a/src/tq.rs
+++ b/src/tq.rs
@@ -72,14 +72,13 @@ where
if let Some(instant) = self.0.peek().map(|p| p.instant) {
if instant < Mono::now() {
- // instant < now
// task became ready
let nr = self.0.pop_unchecked();
Some((nr.task, nr.index))
} else {
// TODO: Fix this hack...
- // Extract the compare time
+ // Extract the compare time.
Mono::set_compare(*instant.duration_since_epoch().integer());
// Double check that the instant we set is really in the future, else
@@ -93,13 +92,9 @@ where
} else {
None
}
-
- // Start counting down from the new reload
- // mem::transmute::<_, SYST>(()).clear_current();
}
} else {
- // The queue is empty
- // mem::transmute::<_, SYST>(()).disable_interrupt();
+ // The queue is empty, disable the interrupt.
disable_interrupt();
None