Skip to content

rust: Replace once_cell with std::sync primitives#273

Merged
emeryberger merged 1 commit intoplasma-umass:masterfrom
camelid:rust-use-std-sync-primitives
Mar 3, 2026
Merged

rust: Replace once_cell with std::sync primitives#273
emeryberger merged 1 commit intoplasma-umass:masterfrom
camelid:rust-use-std-sync-primitives

Conversation

@camelid
Copy link
Copy Markdown
Member

@camelid camelid commented Mar 3, 2026

Summary

  • Replace the once_cell crate with std::sync::OnceLock (for Counter struct) and std::sync::LazyLock (for function-pointer statics), removing the external dependency
  • These std types were stabilized in Rust 1.70 and 1.80 respectively

Test plan

  • cargo check passes
  • cargo test passes (2 smoke tests + 5 doc-tests)

🤖 Generated with Claude Code

Use std::sync::OnceLock and std::sync::LazyLock instead of the
once_cell crate, removing the external dependency. These types were
stabilized in Rust 1.70 and 1.80 respectively.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@emeryberger emeryberger merged commit 9dd3314 into plasma-umass:master Mar 3, 2026
2 checks passed
@camelid camelid deleted the rust-use-std-sync-primitives branch March 3, 2026 03:13
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