aboutsummaryrefslogtreecommitdiff
path: root/rtic-sync/src/channel.rs
diff options
context:
space:
mode:
Diffstat (limited to 'rtic-sync/src/channel.rs')
-rw-r--r--rtic-sync/src/channel.rs3
1 files changed, 3 insertions, 0 deletions
diff --git a/rtic-sync/src/channel.rs b/rtic-sync/src/channel.rs
index 3706e58..3bd7b92 100644
--- a/rtic-sync/src/channel.rs
+++ b/rtic-sync/src/channel.rs
@@ -128,6 +128,9 @@ impl<T, const N: usize> Channel<T, N> {
core::ptr::read(ptr)
};
+ // NOTE: do not `return_free_slot`, as we have mutable
+ // access to this `Channel` and no `Receiver` or `Sender`
+ // exist.
assert!(!self.inner.freeq.as_mut().is_full());
unsafe {
// SAFETY: `freeq` is not ful.