impl PartialOrd, Ord for Script
This commit is contained in:
parent
d1d3b3fb02
commit
68413d306d
|
@ -41,7 +41,7 @@ use util::hash::Hash160;
|
|||
#[cfg(feature="fuzztarget")] use util::sha2::Sha256;
|
||||
#[cfg(not(feature="fuzztarget"))] use crypto::sha2::Sha256;
|
||||
|
||||
#[derive(Clone, PartialEq, Eq, Hash)]
|
||||
#[derive(Clone, Default, PartialOrd, Ord, PartialEq, Eq, Hash)]
|
||||
/// A Bitcoin script
|
||||
pub struct Script(Box<[u8]>);
|
||||
|
||||
|
@ -399,10 +399,6 @@ impl Script {
|
|||
}
|
||||
}
|
||||
|
||||
impl Default for Script {
|
||||
fn default() -> Script { Script(vec![].into_boxed_slice()) }
|
||||
}
|
||||
|
||||
/// Creates a new script from an existing vector
|
||||
impl From<Vec<u8>> for Script {
|
||||
fn from(v: Vec<u8>) -> Script { Script(v.into_boxed_slice()) }
|
||||
|
|
Loading…
Reference in New Issue