Comments (4)
Hi, Thanks for the issue, I found some dead code in the project because of it, But it's incorrect, Waker is registered here before pushing the signal to the signal list:
Lines 92 to 97 in ac93742
and
Lines 179 to 185 in ac93742
and this code was a dead code that I forgot to remove:
{
self.waker = Some(cx.waker().clone())
}
so before pushing the signal to the queue, the waker is already registered, and the possibility of lost wake-ups does not exist.
Feel free to close the issue if you think my explanation is clear.
from kanal.
So as I wrote in the sibling issue: you need to re-register the waker every time because it can change every time poll
is called, so the dead code was actually something that should be done, albeit safely.
from kanal.
Let's continue that subject in #14
from kanal.
Fixed as discussed in #14
from kanal.
Related Issues (20)
- Add Oneshot implementation HOT 17
- Async can't utilize `KanalPtr` as effective as Sync HOT 1
- Are kanal functions cancel-safe? HOT 9
- Miri error when forgetting Box<T> HOT 2
- oneshot deadlock in 0.1.0-pre8 HOT 4
- Intrusive variants HOT 3
- Feature: implement recv_timeout for AsyncReceiver HOT 2
- Kanal is slower than crossbeam HOT 1
- Incorrect Send and Sync bounds HOT 2
- Oneshot: Data race detected HOT 4
- Unsound implementation of `as_sync` HOT 3
- Usage example
- Feature: Provide a select! macro HOT 6
- Slow usize send when using `MiMalloc` HOT 1
- mixing sync and async context HOT 2
- `Stream` that take ownership of the `Receiver` HOT 1
- OneshotSender is not Sync HOT 1
- API design for oneshot sender
- Oneshot: UB triggered when using Axum HOT 2
- Sink impl for AsyncSender?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from kanal.