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 lazy_static with std::sync::LazyLock #123

Merged
merged 1 commit into from
Nov 25, 2024
Merged

Conversation

willbush
Copy link
Member

@willbush willbush commented Oct 30, 2024

lazy_static is no longer needed. We can just use this from std:

https://doc.rust-lang.org/std/sync/struct.LazyLock.html

note: no difference in compile times before / after on my machine. Think compile times are dominated by clap (edit actually maybe regex-syntax in regex crate which can't be removed easily).

Copy link
Member

@infinisil infinisil left a comment

Choose a reason for hiding this comment

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

Since #122 is currently being worked on by a new contributor, let's wait with merging this one a bit until that's done, so as to not require them to resolve a merge conflict, but this sounds good to me :)

@infinisil infinisil merged commit d717a83 into main Nov 25, 2024
3 checks passed
@infinisil infinisil deleted the remove-lazy-static branch November 25, 2024 20:42
@Ben-PH
Copy link
Contributor

Ben-PH commented Nov 27, 2024

Sorry about going quiet and stalling this PR. I'm glad it got merged, and happy to make the updates.

@infinisil
Copy link
Member

No worries!

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.

3 participants