Skip to content

sync.stdatomic: fix bug, add voidptr support, add swap() and compare_… #24685

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

Merged
merged 5 commits into from
Jun 10, 2025

Conversation

kbkpbot
Copy link
Contributor

@kbkpbot kbkpbot commented Jun 10, 2025

…and_swap()

  1. Bug fix: add() and sub() should return atomic's previous value, not it's new value;
  2. Add voidptr type support;
  3. Add swap() and compare_and_swap() support.
  4. More tests.

Copy link

Connected to Huly®: V_0.6-23041

Copy link
Member

@spytheman spytheman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excellent work.

@spytheman
Copy link
Member

(the failing jobs on the CI are not related)

@spytheman spytheman merged commit 0c495d0 into vlang:master Jun 10, 2025
65 of 70 checks passed
@kbkpbot kbkpbot deleted the fix-sync-stdatomic branch June 10, 2025 10:42
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.

2 participants