File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -708,7 +708,7 @@ struct PostorderNodeIterator<'a> {
708
708
709
709
impl < ' a > PostorderNodeIterator < ' a > {
710
710
fn new ( tree : & ' a Tree ) -> Self {
711
- let mut num_nodes_current_tree: usize = 0 ;
711
+ let mut num_nodes_current_tree: tsk_size_t = 0 ;
712
712
let ptr = std:: ptr:: addr_of_mut!( num_nodes_current_tree) ;
713
713
let mut nodes = vec ! [
714
714
NodeId :: NULL ;
@@ -723,7 +723,7 @@ impl<'a> PostorderNodeIterator<'a> {
723
723
tree. as_ptr ( ) ,
724
724
NodeId :: NULL . into ( ) , // start from virtual root
725
725
nodes. as_mut_ptr ( ) . cast :: < tsk_id_t > ( ) ,
726
- ptr. cast :: < tsk_size_t > ( ) ,
726
+ ptr,
727
727
)
728
728
} ;
729
729
@@ -738,7 +738,7 @@ impl<'a> PostorderNodeIterator<'a> {
738
738
Self {
739
739
nodes,
740
740
current_node_index : 0 ,
741
- num_nodes_current_tree,
741
+ num_nodes_current_tree : crate :: util :: handle_u64_to_usize ( num_nodes_current_tree ) ,
742
742
tree : std:: marker:: PhantomData ,
743
743
}
744
744
}
You can’t perform that action at this time.
0 commit comments