Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

removeValue and removeAll are async, which breaks the assumption of Dictionary #5

Open
nikbhatt-cu opened this issue Oct 8, 2023 · 0 comments

Comments

@nikbhatt-cu
Copy link

The implementation of removeValue and removeAll uses self.concurrentQueue.async, which results in a different behavior vs. the regular dictionary. This means it's not a fully drop-in replacement.

If a caller removes a value and then that caller (or a caller of the caller) checks the dictionary, it may still contain the value (for an indeterminate amount of time).

May I ask why these calls must be async?
Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant