Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Harmonize macro usage #1623

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions sdk/src/types/api/plugins/participation/types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ use getset::Getters;
use hashbrown::HashMap;
use packable::PackableExt;

use crate::types::{api::plugins::participation::error::Error, block::impl_id};
use crate::types::api::plugins::participation::error::Error;

/// Participation tag.
pub const PARTICIPATION_TAG: &str = "PARTICIPATE";
Expand Down Expand Up @@ -51,7 +51,7 @@ pub struct ParticipationEvent {
pub data: ParticipationEventData,
}

impl_id!(
crate::impl_id!(
/// A participation event id.
pub ParticipationEventId {
pub const LENGTH: usize = 32;
Expand Down
2 changes: 0 additions & 2 deletions sdk/src/types/block/macro.rs
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,6 @@ macro_rules! impl_id {
)?
};
}
pub(crate) use impl_id;

/// Convenience macro to serialize types to string via serde.
#[cfg(feature = "serde")]
Expand Down Expand Up @@ -297,7 +296,6 @@ macro_rules! create_bitflags {
}
};
}
pub(crate) use create_bitflags;

#[macro_export]
macro_rules! impl_serde_typed_dto {
Expand Down
3 changes: 1 addition & 2 deletions sdk/src/types/block/output/feature/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ pub use self::{
tag::TagFeature,
};
use crate::types::block::{
create_bitflags,
output::{StorageScore, StorageScoreParameters},
Error,
};
Expand Down Expand Up @@ -126,7 +125,7 @@ impl Feature {
crate::def_is_as_opt!(Feature: Sender, Issuer, Metadata, Tag, BlockIssuer, Staking);
}

create_bitflags!(
crate::create_bitflags!(
/// A bitflags-based representation of the set of active [`Feature`]s.
pub FeatureFlags,
u16,
Expand Down
3 changes: 1 addition & 2 deletions sdk/src/types/block/output/unlock_condition/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ pub use self::{
};
use crate::types::block::{
address::Address,
create_bitflags,
output::{StorageScore, StorageScoreParameters},
protocol::ProtocolParameters,
slot::SlotIndex,
Expand Down Expand Up @@ -135,7 +134,7 @@ impl UnlockCondition {
);
}

create_bitflags!(
crate::create_bitflags!(
/// A bitflags-based representation of the set of active [`UnlockCondition`]s.
pub UnlockConditionFlags,
u16,
Expand Down
Loading