Skip to content

Commit cc868a3

Browse files
committed
Make portable-atomic optional
1 parent e7cbd52 commit cc868a3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

embedded-hal-bus/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ std = ["alloc"]
2323
# that does not natively support atomic CAS. If you enable this, you must also add `portable-atomic` to your crate with
2424
# a feature flag such as `unsafe-assume-single-core` or `critical-section` to choose how atomic CAS is implemented.
2525
# See https://docs.rs/portable-atomic/1.7.0/portable_atomic/#optional-features for more info.
26-
portable-atomic = []
26+
portable-atomic = ["dep:portable-atomic"]
2727
# Enable `embedded-hal-async` support.
2828
async = ["dep:embedded-hal-async"]
2929
# Derive `defmt::Format` from `defmt` 0.3 for enums and structs. See https://github.com/knurling-rs/defmt for more info
@@ -36,7 +36,7 @@ embedded-hal = { version = "1.0.0", path = "../embedded-hal" }
3636
embedded-hal-async = { version = "1.0.0", path = "../embedded-hal-async", optional = true }
3737
critical-section = { version = "1.0" }
3838
defmt-03 = { package = "defmt", version = "0.3", optional = true }
39-
portable-atomic = {version = "1.3", default-features = false, features = ["require-cas"]}
39+
portable-atomic = {version = "1.3", default-features = false, optional = true, features = ["require-cas"]}
4040

4141
[package.metadata.docs.rs]
4242
features = ["std", "async"]

0 commit comments

Comments
 (0)