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

Removes lazy_static in favor of OnceLock. #170

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Dygear
Copy link

@Dygear Dygear commented May 3, 2024

The goal here was simply to remove lazy_static in favor of the the standard lib functions that replaced it. This is the smallest number of code changes that I could create to make that happen. I have tested this in my own project and it works as it did before.

@spenserblack
Copy link
Collaborator

spenserblack commented May 3, 2024

Because SHOULD_COLORIZE is public, and the usage now requires calling get_or_init, I believe this counts as a breaking change.

Perhaps until the API from once_cell is fully stabilized as part of the standard library (rust-lang/rust#121377) once_cell::sync::Lazy from the once_cell crate can be used.

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.

None yet

2 participants