@@ -16,7 +16,7 @@ use crate::expression::{self, FromTree};
16
16
use crate :: miniscript:: satisfy:: { Placeholder , Satisfaction , SchnorrSigType , Witness } ;
17
17
use crate :: miniscript:: Miniscript ;
18
18
use crate :: plan:: AssetProvider ;
19
- use crate :: policy:: r#abstract:: Policy ;
19
+ use crate :: policy:: r#abstract:: Policy as Abstract ;
20
20
use crate :: prelude:: * ;
21
21
use crate :: r#abstract:: Liftable ;
22
22
use crate :: util:: { varint_len, witness_size} ;
@@ -617,11 +617,11 @@ fn split_once(inp: &str, delim: char) -> Option<(&str, &str)> {
617
617
}
618
618
619
619
impl < Pk : MiniscriptKey > Liftable < Pk > for TapTree < Pk > {
620
- fn lift ( & self ) -> Result < Policy < Pk > , Error > {
621
- fn lift_helper < Pk : MiniscriptKey > ( s : & TapTree < Pk > ) -> Result < Policy < Pk > , Error > {
620
+ fn lift ( & self ) -> Result < Abstract < Pk > , Error > {
621
+ fn lift_helper < Pk : MiniscriptKey > ( s : & TapTree < Pk > ) -> Result < Abstract < Pk > , Error > {
622
622
match * s {
623
623
TapTree :: Tree { ref left, ref right, height : _ } => {
624
- Ok ( Policy :: Threshold ( 1 , vec ! [ lift_helper( left) ?, lift_helper( right) ?] ) )
624
+ Ok ( Abstract :: Threshold ( 1 , vec ! [ lift_helper( left) ?, lift_helper( right) ?] ) )
625
625
}
626
626
TapTree :: Leaf ( ref leaf) => leaf. lift ( ) ,
627
627
}
@@ -633,12 +633,12 @@ impl<Pk: MiniscriptKey> Liftable<Pk> for TapTree<Pk> {
633
633
}
634
634
635
635
impl < Pk : MiniscriptKey > Liftable < Pk > for Tr < Pk > {
636
- fn lift ( & self ) -> Result < Policy < Pk > , Error > {
636
+ fn lift ( & self ) -> Result < Abstract < Pk > , Error > {
637
637
match & self . tree {
638
638
Some ( root) => {
639
- Ok ( Policy :: Threshold ( 1 , vec ! [ Policy :: Key ( self . internal_key. clone( ) ) , root. lift( ) ?] ) )
639
+ Ok ( Abstract :: Threshold ( 1 , vec ! [ Abstract :: Key ( self . internal_key. clone( ) ) , root. lift( ) ?] ) )
640
640
}
641
- None => Ok ( Policy :: Key ( self . internal_key . clone ( ) ) ) ,
641
+ None => Ok ( Abstract :: Key ( self . internal_key . clone ( ) ) ) ,
642
642
}
643
643
}
644
644
}
0 commit comments