Skip to content

Commit e056c45

Browse files
committed
warnings cleanup
1 parent 62a6a06 commit e056c45

File tree

12 files changed

+12
-10
lines changed

12 files changed

+12
-10
lines changed

rust/src/builders/mint_builder.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,8 @@ struct NativeMints {
4242
}
4343

4444
impl NativeMints {
45+
46+
#[allow(dead_code)]
4547
fn script_hash(&self) -> PolicyID {
4648
match &self.script {
4749
NativeScriptSourceEnum::NativeScript(script, _) => script.hash(),

rust/src/builders/script_structs/script_witness_type.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ pub(crate) enum ScriptWitnessType {
77
}
88

99
impl ScriptWitnessType {
10+
#[allow(dead_code)]
1011
pub(crate) fn script_hash(&self) -> ScriptHash {
1112
match self {
1213
ScriptWitnessType::NativeScriptWitness(script) => script.script_hash(),

rust/src/builders/tx_inputs_builder.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -330,6 +330,7 @@ impl TxInputsBuilder {
330330
.filter_map(|wit| wit.get_script_ref_input_with_size())
331331
}
332332

333+
#[allow(dead_code)]
333334
pub(crate) fn get_required_signers(&self) -> Ed25519KeyHashes {
334335
self.into()
335336
}

rust/src/protocol_types/credentials.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ impl Credentials {
5151
}
5252
}
5353

54+
#[allow(dead_code)]
5455
pub(crate) fn contains(&self, elem: &Credential) -> bool {
5556
self.dedup.contains(elem)
5657
}

rust/src/protocol_types/governance/proposals/voting_proposals.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,7 @@ impl VotingProposals {
6565
voting_proposals
6666
}
6767

68+
#[allow(dead_code)]
6869
pub(crate) fn contains(&self, proposal: &VotingProposal) -> bool {
6970
self.dedup.contains(proposal)
7071
}

rust/src/protocol_types/native_scripts.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ impl NativeScripts {
4646
NativeScripts(scripts)
4747
}
4848

49+
#[allow(dead_code)]
4950
pub(crate) fn contains(&self, script: &NativeScript) -> bool {
5051
self.0.contains(script)
5152
}

rust/src/protocol_types/plutus/plutus_data.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -490,6 +490,7 @@ impl PlutusList {
490490
self.definite_encoding = None;
491491
}
492492

493+
#[allow(dead_code)]
493494
pub(crate) fn contains(&self, elem: &PlutusData) -> bool {
494495
self.elems.contains(elem)
495496
}

rust/src/protocol_types/plutus/plutus_scripts.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ impl PlutusScripts {
3232
self.0.push(elem.clone());
3333
}
3434

35+
#[allow(dead_code)]
3536
pub(crate) fn by_version(&self, language: &Language) -> PlutusScripts {
3637
PlutusScripts(
3738
self.0
@@ -92,6 +93,7 @@ impl PlutusScripts {
9293
PlutusScripts(scripts)
9394
}
9495

96+
#[allow(dead_code)]
9597
pub(crate) fn contains(&self, script: &PlutusScript) -> bool {
9698
self.0.contains(&script)
9799
}

rust/src/protocol_types/plutus/redeemers.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ impl Redeemers {
1818
}
1919
}
2020

21+
#[allow(dead_code)]
2122
pub(crate) fn new_with_serialization_format(
2223
redeemers: Vec<Redeemer>,
2324
serialization_format: CborContainerType,

rust/src/protocol_types/protocol_param_update.rs

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -119,12 +119,6 @@ impl DrepVotingThresholds {
119119
}
120120
}
121121

122-
pub(crate) fn new_default() -> Self {
123-
Self {
124-
..Default::default()
125-
}
126-
}
127-
128122
pub fn set_motion_no_confidence(&mut self, motion_no_confidence: &UnitInterval) {
129123
self.motion_no_confidence = motion_no_confidence.clone()
130124
}

0 commit comments

Comments
 (0)