-
Notifications
You must be signed in to change notification settings - Fork 5
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
Make TryLock::new
const fn
#2
Conversation
Requires Rust 1.31.0 or newer.
This reverts commit e4bd7e5.
@seanmonstar, could you have a look at this? Apart from the constness, it looks like a TryLock would be very useful for static items. |
Pinging here, because I ran into the exact issue and would love to use a crates.io version of this instead of a GitHub fork. Using this in |
@seanmonstar Any thoughts on this? Two years later now, bumping the min version to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
1.21 to 1.31 is a pretty reasonable change at this point. It's still several years ago.
Enables the use of
TryLock::new
in a constant context.Requires Rust 1.31.0 or later and discontinues the support for the older versions. (I'd like to hear your opinion on this - Do you still intend to support Rust 1.21? Or can we drop the support after a major version bump?)