diff --git a/CHANGELOG.md b/CHANGELOG.md index 152a72d..0cddbbb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,7 +2,8 @@ ## Unreleased -- +- `unsync::Lazy` is now covariant in `F` and is smaller for non zero-sized `F`, [#233](https://github.com/matklad/once_cell/pull/233). +- `MSRV` is updated to 1.60.0 to take advantage of `dep:` features. ## 1.17.2 diff --git a/Cargo.toml b/Cargo.toml index 46f9c32..eb87276 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -4,7 +4,7 @@ version = "1.17.2" authors = ["Aleksey Kladov "] license = "MIT OR Apache-2.0" edition = "2021" -rust-version = "1.56" +rust-version = "1.60" description = "Single assignment cells and lazy values." readme = "README.md" @@ -20,17 +20,15 @@ exclude = ["*.png", "*.svg", "/Cargo.lock.msrv", "rustfmt.toml"] members = ["xtask"] [dependencies] -# These optional dependencies are considered private impl details, -# only features from `[features]` table are a part of semver-guarded API. parking_lot_core = { version = "0.9.3", optional = true, default_features = false } -atomic_polyfill = { package = "atomic-polyfill", version = "1", optional = true } -critical_section = { package = "critical-section", version = "1", optional = true } +atomic-polyfill = { version = "1", optional = true } +critical-section = { version = "1", optional = true } [dev-dependencies] lazy_static = "1.0.0" crossbeam-utils = "0.8.7" regex = "1.2.0" -critical_section = { package = "critical-section", version = "1.1.1", features = ["std"] } +critical-section = { version = "1.1.1", features = ["std"] } [features] default = ["std"] @@ -47,12 +45,12 @@ race = [] # Uses parking_lot to implement once_cell::sync::OnceCell. # This makes no speed difference, but makes each OnceCell # up to 16 bytes smaller, depending on the size of the T. -parking_lot = ["parking_lot_core"] +parking_lot = ["dep:parking_lot_core"] # Uses `critical-section` to implement `sync` and `race` modules. in # `#![no_std]` mode. Please read `critical-section` docs carefully # before enabling this feature. -critical-section = ["critical_section", "atomic_polyfill" ] +critical-section = ["dep:critical-section", "dep:atomic-polyfill" ] # Enables semver-exempt APIs of this crate. # At the moment, this feature is unused. diff --git a/xtask/src/main.rs b/xtask/src/main.rs index c4ac864..c3a0541 100644 --- a/xtask/src/main.rs +++ b/xtask/src/main.rs @@ -5,7 +5,7 @@ use std::time::Instant; use xshell::{cmd, Shell}; -const MSRV: &str = "1.56.0"; +const MSRV: &str = "1.60.0"; fn main() -> xshell::Result<()> { let sh = Shell::new()?;