@@ -21,7 +21,7 @@ members = ["xtask"]
21
21
22
22
[dependencies ]
23
23
parking_lot_core = { version = " 0.9.10" , optional = true , default-features = false }
24
- portable-atomic = { version = " 1.7" , optional = true }
24
+ portable-atomic = { version = " 1.7" , optional = true , default-features = false }
25
25
critical-section = { version = " 1.1.3" , optional = true }
26
26
27
27
[dev-dependencies ]
@@ -38,17 +38,23 @@ std = ["alloc"]
38
38
alloc = [" race" ]
39
39
40
40
# Enables `once_cell::race` module.
41
- race = []
41
+ race = [" portable-atomic?/require-cas " ]
42
42
43
43
# Uses parking_lot to implement once_cell::sync::OnceCell.
44
44
# This makes no speed difference, but makes each OnceCell<T>
45
45
# up to 16 bytes smaller, depending on the size of the T.
46
46
parking_lot = [" dep:parking_lot_core" ]
47
47
48
- # Uses `critical-section` to implement `sync` and `race` modules. in
48
+ # Uses `portable-atomic` to implement `race` module. in
49
+ # `#![no_std]` mode. Please read `portable-atomic` docs carefully
50
+ # before enabling this feature.
51
+ portable-atomic = [" dep:portable-atomic" ]
52
+
53
+ # Uses `critical-section` to implement `sync` module. in
49
54
# `#![no_std]` mode. Please read `critical-section` docs carefully
50
55
# before enabling this feature.
51
- critical-section = [" dep:critical-section" , " portable-atomic/critical-section" ]
56
+ # `portable-atomic` feature is enabled for backwards compatibility.
57
+ critical-section = [" dep:critical-section" , " portable-atomic" ]
52
58
53
59
# Enables semver-exempt APIs of this crate.
54
60
# At the moment, this feature is unused.
0 commit comments