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

Replace deprecated compare_and_swap with compare_exchange #2297

Merged
merged 1 commit into from
Dec 25, 2020

Conversation

taiki-e
Copy link
Member

@taiki-e taiki-e commented Dec 25, 2020

compare_and_swap is deprecated in 1.50. (rust-lang/rust#79261)
This patch replaces the uses of compare_and_swap with compare_exchange.

See also the document about compare_and_swap -> compare_exchange(_weak) migration: https://doc.rust-lang.org/nightly/core/sync/atomic/struct.AtomicUsize.html#migrating-to-compare_exchange-and-compare_exchange_weak

@taiki-e taiki-e merged commit 5559680 into rust-lang:master Dec 25, 2020
@taiki-e taiki-e deleted the compare_and_swap branch December 25, 2020 04:58
exrook pushed a commit to exrook/futures-rs that referenced this pull request Apr 5, 2021
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

Successfully merging this pull request may close these issues.

1 participant