Skip to content

Commit

Permalink
Export consensus-any/transaction only if std is enabled
Browse files Browse the repository at this point in the history
  • Loading branch information
moricho committed Dec 2, 2024
1 parent ff28900 commit ae156fa
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
3 changes: 3 additions & 0 deletions crates/consensus-any/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,17 @@
)]
#![cfg_attr(not(test), warn(unused_crate_dependencies))]
#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))]
#![cfg_attr(not(feature = "std"), no_std)]

mod block;
pub use block::AnyHeader;

mod receipt;
pub use receipt::AnyReceiptEnvelope;

#[cfg(feature = "std")]
mod transaction;
#[cfg(feature = "std")]
pub use transaction::{
AnyTxEnvelope, AnyTxType, AnyTypedTransaction, UnknownTxEnvelope, UnknownTypedTransaction,
};
2 changes: 1 addition & 1 deletion crates/network/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ workspace = true

[dependencies]
alloy-consensus = { workspace = true, features = ["std"] }
alloy-consensus-any = { workspace = true, features = ["serde"] }
alloy-consensus-any = { workspace = true, features = ["std", "serde"] }
alloy-eips = { workspace = true, features = ["serde"] }
alloy-json-rpc.workspace = true
alloy-network-primitives.workspace = true
Expand Down
2 changes: 1 addition & 1 deletion crates/rpc-types-any/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ rustdoc-args = ["--cfg", "docsrs"]
workspace = true

[dependencies]
alloy-consensus-any = { workspace = true, features = ["serde"] }
alloy-consensus-any = { workspace = true, features = ["std", "serde"] }
alloy-eips.workspace = true
alloy-network-primitives.workspace = true
alloy-rpc-types-eth = { workspace = true, features = ["serde"] }
Expand Down

0 comments on commit ae156fa

Please sign in to comment.