Skip to content
This repository was archived by the owner on Nov 30, 2022. It is now read-only.

Commit 79786fc

Browse files
committed
f no-std -> core2
1 parent 4819b63 commit 79786fc

File tree

3 files changed

+7
-8
lines changed

3 files changed

+7
-8
lines changed

Cargo.toml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,10 @@ path = "src/lib.rs"
1717
[features]
1818
default = ["std"]
1919
std = []
20-
# The no-std feature enables core2 and the alloc feature adds the alloc crate to that.
21-
# You can still just disable std by disabling default features, without enabling these two.
22-
no-std = ["core2"]
23-
alloc = ["core2/alloc", "no-std"]
20+
# If you disable std, you can still use a Write trait via the core2 feature.
21+
# You can also use ToHex via the alloc feature, as it requires Vec/String.
22+
# And you can still just disable std by disabling default features, without enabling these two.
23+
alloc = ["core2/alloc"]
2424
serde-std = ["serde/std"]
2525
unstable = [] # for benchmarking
2626

embedded/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ cortex-m-rt = "0.6.10"
1414
cortex-m-semihosting = "0.3.3"
1515
panic-halt = "0.2.0"
1616
alloc-cortex-m = { version = "0.4.1", optional = true }
17-
bitcoin_hashes = { path="../", default-features = false, features = ["no-std"] }
17+
bitcoin_hashes = { path="../", default-features = false, features = ["core2"] }
1818
core2 = { version = "0.3.0-alpha.1", default_features = false }
1919

2020
[[bin]]

src/lib.rs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
#[cfg(all(test, feature = "unstable"))] extern crate test;
3939

4040
#[cfg(any(test, feature="std"))] extern crate core;
41-
#[cfg(feature="no-std")] extern crate core2;
41+
#[cfg(feature="core2")] extern crate core2;
4242
#[cfg(any(feature = "std", feature = "alloc"))] extern crate alloc;
4343
#[cfg(feature="serde")] pub extern crate serde;
4444
#[cfg(all(test,feature="serde"))] extern crate serde_test;
@@ -55,8 +55,7 @@ pub mod _export {
5555

5656
#[macro_use] mod util;
5757
#[macro_use] pub mod serde_macros;
58-
#[cfg(any(feature = "std", feature = "no-std"))]
59-
mod impls;
58+
#[cfg(any(feature = "std", feature = "core2"))] mod impls;
6059
pub mod error;
6160
pub mod hex;
6261
pub mod hash160;

0 commit comments

Comments
 (0)